JSON to Android strings.xml Converter
Convert JSON i18n files instantly to Android strings.xml format. Free, no signup.
Would you like to translate it as well?
Convert your files and then translate them with AI into 29 languages. Placeholders like %1$s remain intact.
Translate into 29 languagesHow to convert JSON to Android strings.xml
1. Paste or upload JSON
Paste the contents of your i18n JSON file into the input field. The converter accepts flat and nested JSON structures.
2. Click Convert
The converter flattens nested keys using dot notation (e.g., settings.title) and wraps values with <string> tags. Arrays become <string-array> elements.
3. Copy or download the output
Copy the generated strings.xml to the clipboard or download it directly. Place it in the res/values/ directory of your Android project.
JSON Input
{
"app_name": "My App",
"welcome": "Hello, %1$s!",
"settings": {
"title": "Settings"
}
}strings.xml Output
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">My App</string>
<string name="welcome">Hello, %1$s!</string>
<string name="settings.title">Settings</string>
</resources>JSON vs strings.xml — Format differences
| Feature | JSON | strings.xml |
|---|---|---|
| Simple string | {"key": "value"} | <string name="key">value</string> |
| Nested keys | {"group": {"key": "val"}} | <string name="group.key">val</string> |
| Arrays | {"colors": ["Red", "Blue"]} | <string-array name="colors"><item>...</item></string-array> |
| Placeholder | converter.diffPlaceholdersJson | %d or %1$s |
| Special characters | In JSON escaped | XML entities (& < >) |
| Plural | "one" / "other" Keys | <plurals name="..."><item quantity="one">...</item></plurals> |
Common conversion errors
Nested Keys
Android strings.xml does not support nesting. The converter flattens keys with dot notation: {"settings": {"title": "..."}} becomes name=\"settings.title\". Make sure your Android code reads these flattened keys.
Plurals
JSON plural keys like "one", "other" are not automatically converted to Android <plurals>. For full plural support, wrap them manually with <plurals quantity="..."> after conversion.
Special characters
Apostrophes in strings.xml must be escaped (\\'). The converter does this automatically. Check quotes and the ampersand character in the output.
Placeholder formats
converter.pitfallPlaceholderDesc