How to specify your webpage's language so Google Chrome doesn't offer to translate it

40,323

Solution 1

Google Chrome currently requires several tags to make an (HTML5) document opt out of translation. Before doing this, you should be sure that you know your audience's language, as otherwise it will prevent foreign sites from properly translating your site.

The relevant tags are:

<meta charset="UTF-8" />
<meta name="google" content="notranslate" />
<meta http-equiv="Content-Language" content="en_US" />

And here is a full example:

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8" />
  <meta name="google" content="notranslate" />
  <meta http-equiv="Content-Language" content="en_US" />
 </head>
 <body>
  Dies ist ein Test Deutsch
 </body>

Solution 2

I found a post which might help you: http://www.blogsdna.com/4593/how-to-stop-google-from-translating-your-website-or-webpage.htm

You can either use a meta tag:

<meta name="google" value="notranslate">

Or you can use a class:

<span class="notranslate"></span>

I hope that answered your question.

EDIT: I Just checked my blog which I offer in German and English. On each language version Chrome doesn't ask me for translation: http://kau-boys.de

I checked my source code and the multilanguage plugin only included this code:

<meta http-equiv="Content-Language" content="en_US" /> 

So maybe your locale needs to have a subregion, like US in this example.

Solution 3

You guys should be referencing http://support.google.com/webmasters/bin/answer.py?hl=en&answer=79812 and not guessing what works

<meta name="google" content="notranslate" />

Solution 4

Adding <meta name="google" value="notranslate"> (not W3C by the way) or <meta name="google" content="notranslate"> doesn't avoid the annoying translate popups.

BUT I have tried the following and it seems to work:

You can avoid translation of the page by adding class="notranslate" to the <body> tag!

Solution 5

I have success with <meta name="google" content="notranslate" />

Share:
40,323
dreeves
Author by

dreeves

Startup: Beeminder.com Blog: MessyMatters.com Homepage: Dreev.es Twitter.com/dreev Favorite programming language: Mathematica Random fact: Dreeves is an ultra-marathon inline skater

Updated on July 09, 2022

Comments

  • dreeves
    dreeves almost 2 years

    I have a page that Google Chrome insists on thinking is in French. Here's a snapshot of it:

    http://yootles.com/outbox/overcleverchrome.html

    Note that I'm including a meta http-equiv tag to tell it that it's in fact in English:

    <meta http-equiv="Content-language" content="en">
    

    But it doesn't help. Is there anything else I can do to prevent this?