JSON to XML Converter
Paste JSON on the left, get well-formed XML on the right. The converter wraps your data in a root element, handles nested objects as child elements, and arrays as repeated elements.
How to use this tool
Paste your JSON into the input box on the left. A single root element is automatically added since XML requires one.
Valid XML appears on the right as you type. Nested objects become nested elements; arrays become repeated sibling elements.
Use the Copy button to grab the XML and paste it into SOAP clients, legacy systems, or XML-based APIs.
XML remains common in enterprise environments: SOAP web services, configuration files, SVG, RSS feeds, and Microsoft Office formats all use it. Converting JSON API responses to XML can be useful for integration with these systems.
All processing happens locally in your browser. No data is uploaded.
Frequently asked questions
How are arrays represented in XML?
Arrays become repeated child elements with the same tag name. For example, {"authors": ["A", "B"]} becomes <authors><item>A</item><item>B</item></authors>.
What about XML attributes?
This converter focuses on element-based XML for broad compatibility. Keys starting with @_ in your JSON (a fast-xml-parser convention) are emitted as attributes.
Is there a root element?
Yes. XML requires a single root element. If your top-level JSON is an object, its key becomes the root. Otherwise the data is wrapped in <root> by default.
Can I convert XML back to JSON?
Yes — see our XML to JSON converter. Both directions run client-side.