What is a locale in Shopify?
locale file is a .json file that contains a set of translations for the text strings used in a theme template file. A separate locale file is used for every language supported by a theme (Source: shopify.dev).
Locale changes based on your shop's language
Take an example of the Debut theme where French is one of the supported languages. If you change your theme language to French, the translation filter will retrieve the appropriate French translated string from the
locale file. Then, your theme content will be translated into French, and the
locale passed to your checkout is now
If you are using a third-party translation app to create stores in multiple languages, the translation app will create separate links for each of your stores, and retrieve the theme translation from the
locale file (if the language is available; otherwise, you need to translate it manually). After your multiple language stores are published, if customers who purchase products from your French store, the
locale of their orders will be
fr; similarly, if they purchase from an Italian store, the
locale of their orders will be
*Note: Sometimes the
locale can’t be identified correctly by Shopify.
For example, the default language of your store is English and you also have a store in French. However, when customers place orders on your French store, the
locale of their orders is recorded as
en, rather than
locale is wrong, it may be because your theme is not compatible with multi-language stores. In this case, you can try updating your theme, switch to another theme (all free themes on Shopify are compatible), or contact your theme developer for more information.
The role of a
locale in Multiple Email Templates
Multiple Language Emails lets you send review request emails in multiple languages based on your customers' choice of shop languages when they purchase your products. This means that Candian stores can now send out emails in English and French by creating 2 different email templates and indicating the appropriate language inside the template settings.
To use Multiple Language Emails, you need to follow these steps:
- Step 1: Set up multiple language stores on Shopify (using 3rd party translation apps like Translation Lab). They need to use a theme that is compatible with selling in multiple languages (so far all free themes on Shopify are compatible).
- Step 2: Create an email template for each supported language, and one template for Any Language (in case Shopify fails to identify the customer’s language).
- Step 3:In Template Settings, assign the right Email Language to the right Custom Template. Then activate all the templates.
Judge.me will use the
locale passed to the checkout to match the email template’s language to the customer’s language. For example, if customers purchase products from your French Store, which means the
fr, Judge.me will send them the French Email Template that you have prepared in the email dashboard.
Learn more about creating Multi-language Stores & Multiple Language Emails.