XML ↔ JSON Converter

Convert XML to JSON or JSON back to XML. Handles attributes, text nodes, and arrays sensibly.

Enter input above to see the result.

What is this for?

XML and JSON are the two dominant data interchange formats and you regularly need to translate between them — for migrating from a SOAP API to a REST one, plumbing legacy feeds into a modern stack, or just reading XML in a tool that only speaks JSON. The mapping is opinionated rather than reversible-by-default, because XML has features (attributes, mixed content, ordered children) that JSON doesn't. This tool uses the conventional fast-xml-parser-style mapping: attributes get a prefix (default @), text nodes go to a key (default #text), and repeated child elements collapse to arrays. Both directions run in your browser.

When to use it

Common gotchas