Quickstart

High-quality AI translations built into your development workflow. Translations happen automatically as you build, following style guides and glossaries you've defined. Allowing product teams to ship localized products at speed.

Get started

1. Run the init command in your project directory

npx @localheroai/cli init

This guides you through setup: detecting your translation files, creating localhero.json, and optionally adding a GitHub Actions workflow. You'll need an API key from your account.

2. Choose your workflow

There are two ways to use Localhero.ai to handle your i18n translations:

Automatic (recommended)

During init, select "Yes" to add the workflow file. Then add your API key to GitHub Secrets (you'll get instructions from the command). Every PR with translation changes gets translated automatically.

or

Manual

Select "No" when asked to add the GitHub Action during init. Run commands manually as needed:

npx @localheroai/cli translate

Translates any keys missing translations and saves them to the API.

npx @localheroai/cli pull

Downloads updated translations from the API to your local files.

How it works

Set up once, and automatic translations become part of your normal workflow.

Configure your project

Create a project and specify which languages you support and where your translation files are. JSON, YAML, and .po files all work. Rails, React, Next.js, and others are supported out of the box.

Then define a style guide for your tone of voice and a glossary for terms that need special handling. These guide every translation, so your content sounds like your product, not like generic AI output.

Translations on autopilot

With the GitHub Action installed, translations happen automatically. When a PR adds new strings, they're detected, translated, and committed to your branch. Ready when you merge.

Prefer working locally? The CLI translates as you build.

Stored translations build context over time, so new translations stay consistent with what's already there.

Review and edit from the dashboard

All translations live in the dashboard, where anyone on your team can review and make changes. No code, no dev environment. Sync edits back through an auto-generated PR or by running pull from the CLI.

For build pipelines where translation files aren't in version control, you use the clone command to download translation files in your build process.

Next steps

Need a hand? Drop us a line at hi@localhero.ai