Skip to content

JSON to XML Converter

Convert any JSON to well-formed XML with proper indentation. Configure the root element name, control whether arrays become <items> or repeating siblings, decide whether to encode booleans / numbers as attributes or child elements. Output is properly escaped and parses cleanly in any XML library.

When to use this

Use when: integrating with legacy SOAP APIs that need XML, exporting JSON data for an XML-only enterprise system, feeding JSON-stored config into Java / .NET tools that prefer XML, sending JSON payloads to RSS / Atom feed generators.

Frequently Asked Questions

How are JSON arrays mapped to XML?

Two common patterns: repeated sibling elements (<item>A</item><item>B</item>) or a wrapping parent (<items><item>A</item><item>B</item></items>). The converter defaults to repeating siblings since XML purists prefer it - toggle for wrapped output if your downstream consumer needs the parent.

Will JSON null values come through?

Yes - JSON `null` becomes an empty XML element (<key/>) or `xsi:nil="true"` attribute if you enable XSI nil-handling. XML doesn't have a native null, so the convention varies; pick the one your consumer expects.

Powered by Data Converter - JSON / XML / CSV / YAML.

Other targeted versions of this tool — each tuned for a specific use case.

Or use the main Data Converter - JSON / XML / CSV / YAML if your use case isn't covered above.