Managing shop locales
The ShopLocale type provides the list of primary and alternate locales on a shop. Each locale has two attributes: primary and published. Only one locale can be the primary locale at a time. A shop can have multiple locales in the published or unpublished states.
Merchants can also enable or publish a locale from the Shopify admin.
Shop locale access scopes
To use the shop locale GraphQL mutations, your app needs to request the
write_locales access scope for a Shopify store. For more information on requesting access scopes when your app is installed, see OAuth. You can also enable or publish a locale from the Shopify admin.
Shopify accepts locales in the following formats:
|Tag format||Example tag||Description|
|Language subtag only||en||English|
|Language subtag + region subtag||en-UK||English as spoken in the UK.|
Retrieve a shop's locales
The following query retrieves a list of the shop's enabled locales, including the locale tag, the published state, and whether it is the primary tag.
Enable a locale
A locale must be enabled before it can be published. The
shopLocaleEnable mutation takes a locale tag. We request the shop locale in the response to verify that the locale was enabled correctly.
Publish a locale
Shops are limited to 5 alternate published locales.
Shop locale webooks
You can subscribe to the following Shop locale webhooks:
locale/updatefires when a locale is changed or published.
locale/createfires when a locale is enabled.