Skip to contentSkip to navigationSkip to topbar
Page toolsOn this page
Looking for more inspiration?Visit the

Verify supported languages


Language translations are defined by a locale value, also known as a "language tag". For example, the locale value for English (American) is en.

For any type of Verify template used, the locale will automatically resolve based on the country code of the phone number provided for Verifications sent using the SMS, Voice, or WhatsApp channels, with en or a custom template's default language as the fallback locale if a translation is not available. See a list of phone number country code to language mappings here. Using this automatic resolution is highly recommended. If a language override is desired, you can specify the locale parameter when creating a Verification.

The locale values follow country-region format as described in IETF's BPC 47(link takes you to an external page) for the languages listed below. If an unsupported override locale is given, a 404 error will be returned. In that case, we recommend that you retry the request without the locale parameter to implement a fallback to the country code's default language or English.

(warning)

Warning

SMS messages sent with Programmable Messaging or Verify are priced per message segment.

Messages sent in certain language locales, including pt, pt_BR, cs, and el or in non-GSM characters may be split into multiple message segments. You can check how many message segments your message will use with the Messaging Segment Calculator tool(link takes you to an external page).

Learn more about how to limit message segments in our developer best practices.


Language support and template types

language-support-and-template-types page anchor

Language support depends on the type of Verify template used (Verify Default, pre-approved, custom, WhatsApp copy code authentication) and the channel (SMS, Voice, RCS, or WhatsApp) through which the message is sent. Learn more about template types.

Note: Verify Email and SNA channels don't support language translations.

Verify Default templates

verify-default-templates page anchor

The Verify Default template is used automatically if no pre-approved or custom template is specified in your Verification request or set as the service default.

Pre-approved templates support only a subset of the languages available in Verify. Twilio continues to add more translations and expand language support over time.

  • To check the available languages per-template via API:
    1. View available templates using the Get a List of Available Templates endpoint.
    2. Check the translations property of the template to see supported languages.
  • To check the available languages per-template via Twilio Console:
    1. Navigate to Twilio Console > Verify > Services(link takes you to an external page) page and select your Verify Service.
    2. On the Settings page under the General tab, select a Message body under the Template configuration heading.
    3. Check the Message preview section for Locale Preview dropdown for a list of supported languages.

The template requester must provide translations when making a request to create a custom template(link takes you to an external page).

Each translation must be mapped to a locale value. The template requester can define the locale value, but it must follow these rules:

WhatsApp copy code authentication templates

whatsapp-copy-code-authentication-templates page anchor

WhatsApp OTP messages are sent via WhatsApp copy code authentication templates(link takes you to an external page) that are pre-defined by Meta.


ChannelTemplate typeLanguageLanguage tag/Verify localeWhatsApp localeCopy code text

RCS

Custom

Abkhaz

ab

SMS

Custom

Abkhaz

ab

Voice

Custom

Abkhaz

ab

RCS

Custom

Afar

aa

SMS

Custom

Afar

aa

Voice

Custom

Afar

aa

RCS

Default

Afrikaans

af

SMS

Default

Afrikaans

af

RCS

Custom

Akan

ak

SMS

Custom

Akan

ak

Voice

Custom

Akan

ak

RCS

Custom

Albanian

sq

SMS

Custom

Albanian

sq

Voice

Custom

Albanian

sq


Example: Send an SMS OTP in Spanish

example-send-an-sms-otp-in-spanish page anchor

The following example sends an SMS OTP in Spanish by specifying the es locale in the request.

Send an SMS OTP in SpanishLink to code sample: Send an SMS OTP in Spanish
1
// Download the helper library from https://www.twilio.com/docs/node/install
2
const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";
3
4
// Find your Account SID and Auth Token at twilio.com/console
5
// and set the environment variables. See http://twil.io/secure
6
const accountSid = process.env.TWILIO_ACCOUNT_SID;
7
const authToken = process.env.TWILIO_AUTH_TOKEN;
8
const client = twilio(accountSid, authToken);
9
10
async function createVerification() {
11
const verification = await client.verify.v2
12
.services("VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")
13
.verifications.create({
14
channel: "sms",
15
locale: "es",
16
to: "14155552345",
17
});
18
19
console.log(verification.status);
20
}
21
22
createVerification();

Response

Note about this response
1
{
2
"sid": "VEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
3
"service_sid": "VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
4
"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
5
"to": "14155552345",
6
"channel": "sms",
7
"status": "pending",
8
"valid": false,
9
"date_created": "2015-07-30T20:00:00Z",
10
"date_updated": "2015-07-30T20:00:00Z",
11
"lookup": {},
12
"amount": null,
13
"payee": null,
14
"send_code_attempts": [
15
{
16
"time": "2015-07-30T20:00:00Z",
17
"channel": "SMS",
18
"attempt_sid": "VLaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
19
}
20
],
21
"sna": null,
22
"url": "https://verify.twilio.com/v2/Services/VAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Verifications/VEaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
23
}