Translate

Translate Flutter ARB files

An .arb file is JSON with ICU messages and an @key block of metadata next to every string. KAERIS translates the messages, keeps the metadata and checks the ICU syntax afterwards.

How an ARB file is built

Plain JSON. Each message sits next to an @message entry with its description and placeholder types; @@locale names the language. Plurals and selects are ICU strings: {count, plural, =0{…} one{…} other{…}}.

Source fileapp_en.arb
{
  "@@locale": "en",
  "welcome": "Welcome back, {name}!",
  "@welcome": {
    "description": "Greeting on the home screen",
    "placeholders": { "name": { "type": "String" } }
  },
  "itemCount": "{count, plural, =0{No items} one{{count} item} other{{count} items}}",
  "@itemCount": {
    "placeholders": { "count": { "type": "int" } }
  }
}

What to watch for in ARB translations

A real run: translated to German and checked

A real run, 27 October 2026, nothing edited by hand: kaeris translate app_en.arb --langs de with kaeris 0.2.35, 2.7 seconds, model google/gemini-2.5-flash-lite, the free-tier default. Below, the German file it wrote and what kaeris check says about it.

German resultapp_de.arb
{
  "@@locale": "de",
  "welcome": "Willkommen zurück, {name}!",
  "itemCount": "{count, plural, =0{Keine Artikel} one{{count} Artikel} other{{count} Artikel}}",
  "@welcome": {
    "description": "Greeting on the home screen",
    "placeholders": {
      "name": {
        "type": "String"
      }
    }
  },
  "@itemCount": {
    "placeholders": {
      "count": {
        "type": "int"
      }
    }
  }
}
kaeris checkexit code 0
$ kaeris check --source app_en.arb --langs de
✓ de: complete & placeholder-safe
✓ all locales complete & placeholder-safe

What KAERIS does with it

Run it in three steps

  1. Install the CLI

    Run pip install kaeris.

  2. Translate the template

    Run kaeris translate lib/l10n/app_en.arb --langs de,ja.

  3. Check the result

    Run kaeris check with the source and --pattern 'app_{lang}.arb'; it exits with code 1 on a broken variable or ICU block.

pip install kaeris
kaeris init --preset flutter-arb
kaeris translate lib/l10n/app_en.arb --langs de,ja --verify
kaeris check --source lib/l10n/app_en.arb --langs de,ja --pattern 'app_{lang}.arb'

Questions

Are the @metadata entries kept?

Yes. Descriptions and placeholder types stay next to each message; @@locale is rewritten for the target language.

What if the ICU plural is wrong in a translation?

The check compares ICU blocks with the source and names the problem, for example a dropped =0 branch. In the real run above the plural came back with all three branches and the check had nothing to report.

Is it free?

Yes, without an account: 10,000 characters per file and up to 8 languages per run. A free API key raises the file limit to 50,000 characters. Lifetime is $79 once, on your own OpenRouter key; monthly plans start at $19. Pricing

Can I run it from the terminal or in CI?

Yes. pip install kaeris, then kaeris translate lib/l10n/app_en.arb --langs de,ja. See also Flutter. The GitHub Action runs the same translation in a pull request. CLI docs · GitHub Action

Keep going

CLI reference · Check reference · Translate in the browser · Free check · Convert formats · Pseudo-localization

Other formats: JSON · YAML · .po · XLIFF · .strings · .xcstrings · .properties · .resx · CSV · Markdown · Fluent · Android XML

Framework guides: react-i18next · next-intl · vue-i18n · Flutter · iOS · Android