Adding Locales
Add new languages to your application and email templates.
The template already includes UI dictionaries for en, de, es, fr, ja and zh. To add another locale, keep the existing entries and add its code, label and currency to config.i18n.locales.
- Add
packages/i18n/translations/<locale>.jsonwith the same keys and interpolation variables asen.json, including mail subjects and bodies. - The dynamic import in
packages/i18n/lib/messages.tsloads the matching JSON file by locale name; no separate import registry is needed. - Check locale-sensitive formatting and the language switcher. The app uses the
NEXT_LOCALEcookie, not URL prefixes. - Run the existing checks:
bun run test:i18n-parity
bun run agent:i18n --strict
bun x turbo type-checkDocumentation languages
Public documentation currently ships English and German siblings. Other UI languages use the configured default-language fallback for docs. Do not create untranslated copies merely to fill locale filenames.
To add translated content, use dot suffixes such as overview.fr.mdx and localized meta.fr.json files, preserving slugs and navigation order. The content audit in scripts/agent-i18n-audit.mjs treats any locale with existing translated content as a documentation locale and checks full sibling coverage.
See Authoring docs.