CLI & Code Scanning: Find Every Untranslated String Automatically
Stop hunting through source files for hardcoded strings. Better i18n's CLI uses AST-based parsing to scan your entire codebase, detect untranslated text in JSX components and attributes, report missing and unused keys, and integrate seamlessly into your CI pipeline.
AST-Powered Code Scanning
Unlike regex-based scanners that produce false positives, Better i18n parses your code into an Abstract Syntax Tree for precise, context-aware string detection.
Hardcoded String Detection
Automatically find every user-facing string that is not wrapped in a translation function, including strings in JSX children and component props.
AST-Based Parsing
Parses your source code into an Abstract Syntax Tree for precise, context-aware detection that eliminates the false positives of regex-based scanners.
JSX Text Node Scanning
Detects untranslated text content inside JSX elements, including expressions and template literals rendered directly in your components.
JSX Attribute Scanning
Finds hardcoded strings in JSX attributes like placeholder, aria-label, and title that are often missed during manual i18n audits.
Smart Filtering
Ignores non-translatable values like CSS class names, import paths, and numeric literals so you only see actionable results.
CLI Commands for Translation Auditing
The check command provides an interactive, developer-friendly auditing experience. It compares the translation keys used in your source code against the keys stored in Better i18n's remote, surfacing both missing keys that need translation and unused keys that can be cleaned up.
Dynamic key patterns like template literals are detected automatically. When your code uses t(`key.${variable}`), the CLI recognizes the dynamic segment and includes it in pattern-matched reports, so nothing slips through the cracks.
- Run a full translation audit with a single check command
- Surface missing translation keys that exist in code but not in your remote store
- Identify unused keys in your remote store that are no longer referenced in code
- Detect dynamic key patterns like template literals and flag them for review
- Generate comparison reports between local usage and remote translation state
Flexible Output Formats
Scan results are available in multiple formats to fit your workflow. ESLint-style output gives human-readable reports with file, line, and column references. JSON output provides machine-readable data for CI/CD automation and custom tooling.
Verbose mode delivers deep transparency with detailed audit logs, scoping summaries, and timing information. Scan statistics show file counts, discovery metrics, and performance data so you always know the health of your translation coverage.
ESLint-Style Output
Human-readable reports with file path, line number, and column references for fast navigation in any editor.
JSON Output
Machine-readable structured data ideal for CI/CD automation, custom dashboards, and integration with other tooling.
Verbose Mode
Detailed audit logs with scoping summaries, timing information, and namespace resolution traces for debugging.
Scan Statistics
File counts, key discovery metrics, and performance data so you always know the health of your translation coverage.
DevOps & CI/CD Integration
Embed translation checks into your existing development pipeline to catch missing strings before they reach production.
CI Pipeline Integration
Add a scan step to your CI workflow that fails the build when untranslated strings or missing keys are detected.
Pre-Commit Hooks
Run scans on staged files before each commit to catch untranslated strings at the earliest possible point in development.
Directory-Scoped Scanning
Target specific directories or file patterns to scan only the parts of your codebase that contain user-facing content.
Scope-Aware Analysis
Automatically resolve translation namespaces through lexical scope tracking so each t() call maps to the correct key set.
Better i18n CLI: Code Scanning Built for Localization
Better i18n's CLI combines AST-based code scanning with remote key management in a single tool. Scan your codebase for hardcoded strings, compare local usage against your remote translation store, detect unused keys that inflate bundle size, and generate reports for your CI pipeline — all without leaving your terminal.
Scope-Aware Scanning
Tracks useTranslations and getTranslations calls through lexical scopes, binding each t() call to its correct namespace automatically.
Server Component Support
Full support for Next.js App Router async server components, so getTranslations calls in server code are detected and audited alongside client-side usage.
Pre-Commit Hooks
Run scans on staged files only with the --staged flag, catching untranslated strings before they are committed without slowing down your workflow.
Related Topics
For Developers
Developer-focused i18n tools with type-safe SDKs and Git-first workflows
Localization Software
TMS and CAT tools for managing translations at scale
Localization Software
TMS and CAT tools for managing translations at scale
Translation Management System
Centralize your localization workflow with a TMS
Ship Translations Without Missing a String
Better i18n's CLI scans your code, detects every untranslated string, and fits into your CI pipeline so nothing reaches production without a translation.