--- title: MatchingTranslations description: Looks for missing or additional translations in locale files. source_url: html: >- https://shopify.dev/docs/storefronts/themes/tools/theme-check/checks/matching-translations md: >- https://shopify.dev/docs/storefronts/themes/tools/theme-check/checks/matching-translations.md --- ExpandOn this page * [Examples](https://shopify.dev/docs/storefronts/themes/tools/theme-check/checks/matching-translations.md#examples) * [Auto-correction](https://shopify.dev/docs/storefronts/themes/tools/theme-check/checks/matching-translations.md#auto-correction) * [Options](https://shopify.dev/docs/storefronts/themes/tools/theme-check/checks/matching-translations.md#options) * [Disabling this check](https://shopify.dev/docs/storefronts/themes/tools/theme-check/checks/matching-translations.md#disabling-this-check) # MatchingTranslations Identifies missing or additional translations in [locale files](https://shopify.dev/docs/storefronts/themes/architecture/locales). *** ## Examples The following examples contain code snippets that either fail or pass this check. ### ✗ Fail The following locale files aren't consistent: ## en.default.json ```json { "greeting": "Hello, world", "goodbye": "Bye, world" } ``` `es.json` is missing `greeting` and `goodbye` translations: ## es.json ```json { } ``` `fr.json` is missing `greeting` and has a `goodby` tag that isn't present in the default locale: ## fr.json ```json { "goodby": "Au revoir, monde" } ``` ### ✓ Pass The following locale files are consistent: ## en.default.json ```json { "greeting": "Hello, world", "goodbye": "Bye, world", "pluralized_greeting": { "one": "Hello, you", "other": "Hello, y'all", } } ``` ## fr.json ```json { "greeting": "Bonjour, monde", "goodbye": "Au revoir, monde", "pluralized_greeting": { "zero": "Je suis seul :(", "few": "Salut, groupe!" } } ``` *** ## Auto-correction Theme Check can correct this error using the `--auto-correct` flag. When the flag is specified, Theme Check automatically adds missing translation keys and removes extra translation keys for all non-default locales. *** ## Options The following example contains the default configuration for this check: ```yaml MatchingTranslations: enabled: true severity: error ``` | Parameter | Description | | - | - | | `enabled` | Whether the check is enabled. | | `severity` | The [severity](https://shopify.dev/themes/tools/theme-check/configuration#check-severity) of the check. | *** ## Disabling this check Disabling this check isn't recommended because it might result in an inconsistent translation experience for some users. *** * [Examples](https://shopify.dev/docs/storefronts/themes/tools/theme-check/checks/matching-translations.md#examples) * [Auto-correction](https://shopify.dev/docs/storefronts/themes/tools/theme-check/checks/matching-translations.md#auto-correction) * [Options](https://shopify.dev/docs/storefronts/themes/tools/theme-check/checks/matching-translations.md#options) * [Disabling this check](https://shopify.dev/docs/storefronts/themes/tools/theme-check/checks/matching-translations.md#disabling-this-check)