i18n-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@i18n-mcpList missing translation keys for the Thai locale"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
i18n-mcp
An MCP (Model Context Protocol) server that gives coding agents tools to manage
Rails-style localization files (YAML or JSON). Point it at a Rails app's
config/locales directory and the agent can read, search, write and audit
translations without hand-editing files.
Supported layouts
Both common Rails layouts are detected automatically, and can be mixed:
config/locales/
en/ # per-locale directories (nesting allowed)
common.yml # rooted at the locale code: `en: ...`
admin/users.yml
th/common.yml
legacy.yml # flat files whose top-level keys are locale codesFiles may be .yml, .yaml or .json. Writes go through the YAML AST, so
existing comments and key order survive edits. Duplicate keys are tolerated
with last-wins semantics, matching Rails (Psych). Files that cannot be parsed
are reported in locales output under problems instead of aborting
the server.
Related MCP server: mcp-locator
Install and build
Run directly from npm without installing:
npx -y mcp-i18n --locales-dir /path/to/rails-app/config/localesOr build from source:
npm install
npm run buildUsage with an MCP client
Add the server to your MCP client configuration (Kimi Code, Claude Desktop, etc.). Via npx (no local checkout needed):
{
"mcpServers": {
"i18n": {
"command": "npx",
"args": [
"-y", "mcp-i18n",
"--locales-dir", "/path/to/rails-app/config/locales"
]
}
}
}Or from a local build:
{
"mcpServers": {
"i18n": {
"command": "node",
"args": [
"/path/to/i18n-mcp/dist/src/index.js",
"--locales-dir", "/path/to/rails-app/config/locales"
]
}
}
}Options:
--locales-dir <path>— locales directory. Falls back to theI18N_LOCALES_DIRenvironment variable, then<cwd>/config/locales.--default-file <name>— file name (relative to the locale directory) for brand-new keys. Default:common.yml(orcommon.jsonfor JSON-only locales).
Tools
Tool | Description |
| List locales with file/key counts and parse problems. |
| List translation key paths; filter by |
| Get a key's values across locales, with the file each lives in. |
| Substring search over translation keys (optionally values). |
| Create or update a key per locale. Writes to the key's current file, the nearest prefix's file, or the locale default. Warns on |
| Delete a key from locales (default: all); prunes empty parents. |
| Audit keys: missing per locale, empty values, |
Examples
// get_key
{ "key": "roles_scope.super_admin" }
// set_key
{ "key": "features.reports.title", "values": { "en": "Reports", "th": "Reports (th)" } }
// missing, scoped to one subtree
{ "prefix": "dashboards", "limit": 50 }All responses are JSON. Errors (unknown locale, missing key, write failures) are returned as tool errors with a human-readable message.
Development
npm test # vitest unit/handler tests
npm run coverage # tests + v8 coverage report (enforced thresholds: 85% lines/statements, 80% branches/functions)
npm run lint # eslint (zero errors required)
npm run typecheck # tsc --noEmit, strict (zero errors required)
npm run build # compile to dist/
npm run smoke # end-to-end test over real stdio transportAvailable Tools
7 toolsdelete_keyA
Delete a key from locales (default: all); prunes empty parents.
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | Dot-separated key path, e.g. "roles_scope.super_admin" | |
| locales | No | Default: all locales |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the burden. It discloses the side effect of pruning empty parents and the default locale scope, which is useful. However, it omits other destructive-operation details like reversibility or return values, though the verb 'Delete' signals irreversibility.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence that immediately states the action and resource, then adds a concise behavioral note. No wasted words, earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (2 params, no output schema, no annotations), the description adequately covers the purpose, scope, and a key side effect. A minor gap is the lack of explicit error or return behavior, but this is not required without an output schema.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the baseline is 3. The description adds no extra parameter meaning beyond what the schema already contains; the 'default: all' for locales is duplicated from the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool deletes a key from locales, with a specific verb and resource. It distinguishes itself from siblings like get_key, set_key, and search by the 'Delete' action.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage (when you want to delete a key) and notes the default behavior (all locales), but does not explicitly compare alternatives or state when not to use it. No exclusion criteria or alternative tool references are provided.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_keyA
Get a key's values across locales, with the file each lives in.
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | Dot-separated key path, e.g. "roles_scope.super_admin" | |
| locales | No | Default: all locales |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. The word 'Get' clearly signals a non-destructive read operation, and the added detail about returning the file each value lives in provides useful output behavior context. However, it does not mention error handling or sorting, but these are not critical for such a simple tool.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence that conveys purpose, scope, and output detail without any redundant words. It earns its place entirely.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the simple tool complexity, a 2-parameter schema with full coverage, and no output schema, the description is reasonably complete. It explains what the tool returns (values and the file), which partially compensates for the lack of an output schema. Minor gaps like missing-key behavior are acceptable at this simplicity level.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema already provides 100% coverage with descriptions for 'key' (dot-separated key path, e.g. 'roles_scope.super_admin') and 'locales' (default: all locales). The description's phrase 'across locales' aligns with the 'locales' parameter but adds no new semantic detail beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description 'Get a key's values across locales, with the file each lives in' clearly states the verb ('Get'), resource ('a key's values'), scope ('across locales'), and an additional detail ('with the file each lives in'). This distinguishes it from sibling tools like 'keys' (listing all keys) and 'search' (fuzzy lookup).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies the tool is used to retrieve a specific key's translations, but it does not explicitly state when to use it over alternatives like 'search' or 'missing'. The context is clear enough for a simple read operation, but there are no explicit when-to-use or when-not-to-use directions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
keysA
List translation key paths; filter by locale and/or prefix.
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Max results (default 200) | |
| locale | No | Only this locale | |
| prefix | No | Only keys at/below this prefix |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full transparency burden. It states it lists key paths and can filter, but it does not disclose pagination behavior, default limits, or explicitly state that it is a read-only operation. This is minimal for a list tool and does not add context beyond what the schema already provides.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence, front-loaded with the action ('List translation key paths'), and includes the key filtering capability with no superfluous words. It is concise and well-structured.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool is simple with optional filters, and the description covers the primary use case. However, with no output schema or annotations, it does not explain return format, default behaviors, or edge cases. It is adequate but not fully complete for an agent that might need more context on what the tool returns or how it behaves.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema covers all three parameters (limit, locale, prefix) with descriptions, so the baseline is 3. The description adds that locale and prefix are filters, but this is already implied by the schema's parameter descriptions. No new semantic meaning is provided beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses the specific verb 'List' and clearly identifies the resource as 'translation key paths'. It also mentions filtering by locale and/or prefix, which distinguishes it from sibling tools like get_key (single key) and search (likely more complex). The purpose is unambiguous and directly actionable.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives clear context for when to use this tool (listing translation key paths, optionally filtered), but it does not explicitly contrast with alternatives such as search or get_key. There is no when-not-to-use guidance or mention of alternative tools, leaving usage somewhat implied.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
localesA
List locales with file/key counts and parse problems.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the burden. It implies a read-only list operation, but does not explicitly state that it performs no modifications or mention any potential side effects or performance characteristics. Adequate for a simple list tool but with gaps.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, concise sentence with no filler. It front-loads the action and resource, followed by the specific output details.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's low complexity (no parameters, no annotations, no output schema), the description adequately explains what the tool returns and the context in which it is used. Nothing critical is missing for a simple list operation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
There are zero parameters, so the schema provides no semantic information. The description doesn't need to explain parameters because none exist. Baseline for 0 params is 4.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('List'), the resource ('locales'), and the specific data included (file/key counts and parse problems). It is distinct from sibling tools like 'keys' or 'missing', which focus on other aspects.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies this tool is for getting an overview of locales, but it does not explicitly say when to choose it over siblings. No alternatives or exclusions are mentioned, though the context makes it fairly obvious.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
missingA
Audit keys: missing per locale, empty values, %{placeholder} mismatches vs base locale (default: en).
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Max issues (default 100) | |
| prefix | No | Only keys at/below this prefix | |
| baseLocale | No | Reference locale (default: en) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description must carry the full burden of behavioral context. It adds the comparison against a base locale with default 'en' and lists three audit checks, which is useful. However, it does not state whether the tool is read-only, what the output format looks like, or any operational constraints, leaving important behavioral details undisclosed.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single compact sentence that front-loads the main verb 'Audit' and packs in the key checks and default locale. It is dense but not overly verbose, with every phrase contributing to the meaning. A minor deduction for the slightly list-like enumeration, but overall efficient.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the lack of an output schema, the description should indicate what the tool returns (e.g., a list of issues and their locations). It only states what it checks, not the response format or behavior, leaving a significant gap for an agent to understand the tool's full behavior and how to consume its results.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema already provides descriptions for all three parameters (100% coverage), so the schema carries the parameter semantics. The description's mention of 'base locale (default: en)' restates the baseLocale parameter without adding new meaning beyond the schema. Thus, it neither compensates for gaps nor enhances understanding.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states a specific action (audit) on keys and enumerates three distinct checks (missing per locale, empty values, placeholder mismatches), distinguishing it from sibling tools like get_key or search. It is a specific verb+resource combination with clear scope.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The usage context is implied: it is for auditing translation consistency relative to a base locale. However, there is no explicit guidance on when to use this tool vs alternatives, nor any mention of exclusions or edge cases, so the guidance remains implicit rather than direct.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
searchB
Substring search over translation keys (optionally values).
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Max results (default 50) | |
| query | Yes | Substring to find | |
| locale | No | Only this locale | |
| searchValues | No | Also match values |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
There are no annotations, so the description must carry the full burden of behavioral disclosure. It states the core search behavior and optional value matching, but omits details such as case sensitivity, result ordering, pagination behavior, or the shape of the response. For a search tool, this lacks important behavioral context.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence with no filler or redundant content. Every word earns its place, making it appropriately concise.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool has 4 parameters, no annotations, and no output schema. The description only conveys the basic purpose, leaving users to guess how limit, locale, and searchValues interact, and what the response contains. Given the minimal structured context, the description is incomplete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema already provides descriptions for all 4 parameters (100% coverage), so the baseline is 3. The description adds little beyond the schema—'optionally values' echoes the searchValues parameter description without providing new meaning.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb 'substring search' and a clear resource ('translation keys'), and even notes the optional scope expansion to values. This distinguishes it from sibling tools like 'keys' (likely listing all keys) and 'get_key' (exact lookup).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies a search use case but does not explicitly state when to prefer this over sibling tools like 'keys' or 'get_key', nor does it mention any exclusions. The intent is inferable from the name and phrasing, but there is no direct guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
set_keyA
Create or update a key per locale. Writes to the key's current file, the nearest prefix's file, or the locale default. Warns on %{placeholder} mismatch.
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | Dot-separated key path, e.g. "roles_scope.super_admin" | |
| file | No | Target file (absolute, or relative to the locale dir) | |
| values | Yes | Locale code → translation |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden. It discloses file placement logic and warns on placeholder mismatch, which is useful. However, it doesn't mention overwriting behavior, error handling, or permission requirements, leaving some important behavioral traits undisclosed.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three short sentences, each contributing distinct value: purpose, file selection logic, and placeholder warning. There is no fluff or repetition.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a moderate-complexity tool with no output schema and no annotations, the description covers the core behavior and important edge cases (file selection, placeholder warning). It doesn't explain return values or error states, but for a mutation tool this is acceptable. The description is sufficiently complete for an agent to use it correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the baseline is 3. The description adds extra meaning by explaining how the optional 'file' parameter falls back to the current file, nearest prefix, or locale default. It also hints at validation of 'values' via placeholder mismatch warnings.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb+resource pair ('Create or update a key per locale') and clearly distinguishes this from sibling tools like get_key, delete_key, and search. It also explains the file selection behavior, which further clarifies the tool's scope.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description conveys clear context for when to use this tool: when creating or updating a key per locale. It doesn't explicitly name alternatives or exclusions, but the purpose is unambiguous enough for an agent to select it over read/search/delete tools.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
7 tool updates
v0.1.0- First observed
delete_key - First observed
get_key - First observed
keys - First observed
locales - First observed
missing - First observed
search - First observed
set_key
TDQS
Scored across 7 tools
Each tool has a clear, distinct role: listing locales, listing keys, fetching a specific key, searching, setting, deleting, and auditing. No two tools appear to do the same thing.
Tool names follow a consistent, predictable pattern: plural nouns for listing actions (keys, locales), and verb_noun for operations (get_key, set_key, delete_key). The one outlier, 'missing', is still clear as an audit verb.
Seven tools is a well-scoped count for an i18n management server, covering the essential operations without bloat.
The toolset provides full lifecycle coverage for translation keys: read (keys, get_key, search), write (set_key), delete (delete_key), and audit (missing, locales). Minor operations like rename/move are possible via set+delete, so no dead ends.
Maintenance
Related MCP Connectors
Lingo.dev MCP Server - World-class i18n implementation with ICU MessageFormat.
MCP server for Crowdin — projects, files, strings, translation progress, tasks, and members.
MCP server for Translation Services
Phrase MCP server: language intelligence platform for translation, terminology, and quality.
Related MCP Servers
- AlicenseAqualityBmaintenanceMCP server for managing i18n JSON translation files. Provides Claude with structured read/write access to translation files for adding keys, checking coverage, and finding duplicates.1222 npm1MIT
- AlicenseNot gradedqualityDmaintenanceAn MCP server that lets AI agents read and write locale JSON translation files directly from the conversation without loading the whole catalog into context.11 npm1ISC
- AlicenseAqualityBmaintenanceMCP server for managing i18n translation files — gives your AI agent full control over your app's translations without dumping entire locale files into context.15251 npm11MIT
- AlicenseNot gradedqualityBmaintenanceOpen-source, self-hosted translation management system with an MCP server that enables AI agents to manage projects, locales, keys, and translations via natural language, and includes a CLI for deterministic file syncing.1MIT