Google Translation Extension

Google Translate Extension

Hello everyone,
I hope you all are doing well, before some time I have seen someone has requested for translation function in his/her app, so I have created a simple GoogleTranslate extension with the help of Google App Script.




Description: Event raised when translated text got.

  1. translatedText: String value of source text in the target language.



Description: Translate your text to the target language from the source language.

  1. text: String value of source text that you want to translate.
  2. sourceLang: Source language code given by Google.
  3. targetLang: Target language code given by Google,

language codes


Description: Set your own deployment key after deployment in case if you don't want to deploy your own web app use this key



Google App Script

Step: 1

Go to Google App Script and create a new project. link

Step: 2

Copy the given script and paste it into your project.
Click on the save button and deploy it.

function doGet(e) {
  let sourceLang =;
  let destLang = e.parameters.dl;
  let text = e.parameters.text;
  let transletedText = LanguageApp.translate(text.toString(), sourceLang.toString(), destLang.toString());
  return ContentService.createTextOutput(transletedText).setMimeType(ContentService.MimeType.JSON);

Step : 3

Set the deployment configuration shown in the given picture, now hit on the deploy button and copy-paste it into App Inventor.


  1. The default deployment key and the key which you see in the picture is only for testing, I am not sure it will help you in the future or not, so I recommend you deploy your own script as a web app.
  2. If you find any kind of problem then, please write in this thread.

Download Link

GoogleTranslate (2).aix (6.5 KB)

Thanks and Regards
Preet P. Vadaliya


You can request 5000 times in a day with your free Google account, for more information you can see this page...

Quotas for Google Services  |  Apps Script  |  Google Developers

Nice extension...

But I think you should rename APIKey to ApiKey, since API is one term.

The YandexTranslate component uses the ApiKey naming convention.

But still, great extension.


you can use this also to translate

1 Like

(added to FAQ)

1 Like