5 min read

#superUser 2: Webpage Translation - Zero Installation

As long as your browser allows a custom search engine
#superUser 2: Webpage Translation - Zero Installation

Setup


In any browser, you can translate a webpage via Google API:

https://translate.google.com/translate?sl=auto&tl=en&u=<URL to be translated>

or Bing:

https://www.translatetheweb.com/?ref=TVert&from=&to=en&a=<URL to be translated>

As long as your browser allows a custom search engine, you can add the APIs as a custom search engine:

In most cases, <URL to be translated> is represented by %s.Therefore, you can write:

Name: Google Page Translation
Alias: gtr
URL: https://translate.google.com/translate?sl=auto&tl=en&u=%s

Name and Alias are arbitrary. The name is cosmetic and for your convenience, while the alias is the prefix you would type in your address bar to activate this webpage translation API/'search engine'.

Afterwards, a webpage can be translated by typing <alias> + URL

Example


For instance, to translate this page, which is in French, you can go to the page, and prefix your alias to the page URL.

And you should see something like this:

If you are instead sent to the translation service's home page. Try removing protocol prefixes such as https:// from <URL to be translated> , which may cause an error. Most translation services handle errors by sending you to their homepage.

If that does not help, try again with another service. APIs are opened and closed as the Tech Giants are pleased.

Big Tech, I mean.

Switching languages


https://translate.google.com/translate?sl=auto&tl=en&u=<URL to be translated>

In most translation API URLs, the source and destination languages are specified by switches in the URL.

For Google Translate, the source language is specified by sl=<source language>, which you can specify as auto if you are not overly concerned about speed. Destination language is specified by tl=<destination language>, which is represented by 2-letter abbreviations.

Below is an incomplete list of possible abbreviations. Use your browser's search function, usually triggered by CTRL + F to locate your target language.

Code Language Code Language Code Language Code Language
af Afrikaans ak Akan sq Albanian am Amharic
ar Arabic hy Armenian az Azerbaijani eu Basque
be Belarusian bem Bemba bn Bengali bh Bihari
xx-bork Bork, bork, bork! bs Bosnian br Breton bg Bulgarian
km Cambodian ca Catalan chr Cherokee ny Chichewa
zh-CN Chinese (Simplified) zh-TW Chinese (Traditional) co Corsican hr Croatian
cs Czech da Danish nl Dutch xx-elmer Elmer Fudd
en English eo Esperanto et Estonian ee Ewe
fo Faroese tl Filipino fi Finnish fr French
fy Frisian gaa Ga gl Galician ka Georgian
de German el Greek gn Guarani gu Gujarati
xx-hacker Hacker ht Haitian Creole ha Hausa haw Hawaiian
iw Hebrew hi Hindi hu Hungarian is Icelandic
ig Igbo id Indonesian ia Interlingua ga Irish
it Italian ja Japanese jw Javanese kn Kannada
kk Kazakh rw Kinyarwanda rn Kirundi xx-klingon Klingon
kg Kongo ko Korean kri Krio (Sierra Leone) ku Kurdish
ckb Kurdish (Soranî) ky Kyrgyz lo Laothian la Latin
lv Latvian ln Lingala lt Lithuanian loz Lozi
lg Luganda ach Luo mk Macedonian mg Malagasy
ms Malay ml Malayalam mt Maltese mi Maori
mr Marathi mfe Mauritian Creole mo Moldavian mn Mongolian
sr-ME Montenegrin ne Nepali pcm Nigerian Pidgin nso Northern Sotho
no Norwegian nn Norwegian (Nynorsk) oc Occitan or Oriya
om Oromo ps Pashto fa Persian xx-pirate Pirate
pl Polish pt-BR Portuguese (Brazil) pt-PT Portuguese (Portugal) pa Punjabi
qu Quechua ro Romanian rm Romansh nyn Runyakitara
ru Russian gd Scots Gaelic sr Serbian sh Serbo-Croatian
st Sesotho tn Setswana crs Seychellois Creole sn Shona
sd Sindhi si Sinhalese sk Slovak sl Slovenian
so Somali es Spanish es-419 Spanish (Latin American) su Sundanese
sw Swahili sv Swedish tg Tajik ta Tamil
tt Tatar te Telugu th Thai ti Tigrinya
to Tonga lua Tshiluba tum Tumbuka tr Turkish
tk Turkmen tw Twi ug Uighur uk Ukrainian
ur Urdu uz Uzbek vi Vietnamese cy Welsh
wo Wolof xh Xhosa yi Yiddish yo Yoruba
zu Zulu

List of gratitude


Those resources have been immensely helpful to the composition of this article:

Article by JT5D:

Google translate language codes
Google translate language codes. GitHub Gist: instantly share code, notes, and snippets.

Forum post by ra-mon:

Astuce Vivaldi : Traduction de page sans extension
À compter de la version 3.8 (en cours de développement en mars 2021), Vivaldi intègre un traducteur de page respectueux de la vie privée (solution technique…

Énoncé du droit d'auteur


Much of our content is freely available under the Creative Commons BY-NC-ND 4.0 licence, which allows free distribution and republishing of our content for non-commercial purposes, as long as Ronzz.org is appropriately credited and the content is not being modified materially to express a different meaning than it is originally intended for. It must be noted that some images on Ronzz.org are the intellectual property of third parties. Our permission to use those images may not cover your reproduction. This does not affect your statutory rights.

Nous mettons la plupart de nos contenus disponibles gratuitement sous la licence Creative Commons By-NC-ND 4.0, qui permet une distribution et une republication gratuites de notre contenu à des fins non commerciales, tant que Ronzz.org est correctement crédité et que le contenu n'est pas modifié matériellement pour exprimer un sens différent que prévu à l'origine.Il faut noter que certaines images sur Ronzz.org sont des propriétés intellectuelles de tiers. Notre autorisation d'utiliser ces images peut ne pas couvrir votre reproduction. Cela n'affecte pas vos droits statutaires.