Supported languages
PolyLingo supports 36 base languages and 7 regional variants — 43 language codes in total. Pass any code from the tables below as a value in the targets array of any translate endpoint.
Base languages
| Code | Language | RTL |
|---|---|---|
ar | Arabic | Yes |
bn | Bengali | |
bg | Bulgarian | |
hr | Croatian | |
cs | Czech | |
da | Danish | |
nl | Dutch | |
en | English | |
fi | Finnish | |
fr | French | |
de | German | |
el | Greek | |
he | Hebrew | Yes |
hi | Hindi | |
hu | Hungarian | |
id | Indonesian | |
it | Italian | |
ja | Japanese | |
ko | Korean | |
ms | Malay | |
no | Norwegian | |
fa | Persian (Farsi) | Yes |
pl | Polish | |
pt | Portuguese | |
ro | Romanian | |
ru | Russian | |
sk | Slovak | |
es | Spanish | |
sw | Swahili | |
sv | Swedish | |
th | Thai | |
tr | Turkish | |
uk | Ukrainian | |
vi | Vietnamese | |
zh | Chinese (Simplified) | |
zh-TW | Chinese (Traditional) |
Regional variants
Regional variants use BCP-47 language-region subtag codes — the same convention used by browsers, operating systems, and i18n frameworks. Use them when your audience expects a specific regional register, vocabulary, or spelling convention.
| Code | Language | Parent |
|---|---|---|
en-GB | English (UK) | en |
es-ES | Spanish (Spain) | es |
es-MX | Spanish (Mexico) | es |
fr-CA | French (Canada) | fr |
pt-BR | Portuguese (Brazil) | pt |
pt-PT | Portuguese (Portugal) | pt |
zh-HK | Chinese (Hong Kong) | zh |
When to use a regional variant
Use the generic code (fr, es, pt) when you need broad coverage or when your audience spans multiple regions. Use a regional code when your content targets a specific market — for example, pt-BR for a Brazilian product or en-GB for a UK publication.
Regional codes and their generic counterparts can be mixed freely in the same request:
{
"targets": ["fr", "fr-CA", "pt", "pt-BR"]
}
The response includes a separate translation keyed by each code you requested:
{
"translations": {
"fr": "Bonjour le monde",
"fr-CA": "Allô le monde",
"pt": "Olá mundo",
"pt-BR": "Olá mundo"
}
}
Discover languages at runtime
GET /languages returns the live canonical list — no hardcoding required:
curl https://api.usepolylingo.com/v1/languages
Response includes every supported code with its display name and RTL flag:
{
"languages": [
{ "code": "en", "name": "English", "rtl": false },
{ "code": "en-GB", "name": "English (UK)", "rtl": false },
{ "code": "fr", "name": "French", "rtl": false },
{ "code": "fr-CA", "name": "French (Canada)", "rtl": false }
]
}
RTL languages
Arabic (ar), Hebrew (he), and Persian/Farsi (fa) are right-to-left. For plain and markdown output the API returns translated text only — set text direction in your UI using CSS direction: rtl or a parent element's dir="rtl" attribute. For html format, dir="rtl" is added to appropriate block-level elements automatically. See the API reference for details.