Runs in your browser

JSON to XML Converter Online

Paste JSON and get well-formed XML. Arrays become repeated elements, and the table below shows how everything is mapped.

JSON input

Paste JSON here, open a file or drop it here…

XML output

The result appears here.
How XML and JSON are mapped

Both converters use the same reversible mapping, so XML → JSON → XML gives the same document. JSON null and [] become an empty element, and arrays inside arrays become nested <item> elements. Invalid names are corrected and listed.

XMLJSON
Root element <ORDERS05>{ "ORDERS05": … } – the name is kept
Element with text only"text" (string, unchanged)
Empty element""
Attribute id="1""@id": "1"
Namespace declaration"@xmlns:ns0": "urn:…"; prefixes stay in names ("ns0:Order")
Text next to attributes or children"#text": "…"
CDATA section"#cdata": "…"
Comment"#comment": "…"
Processing instruction <?target data?>"?target": "data"
Mixed content (text and elements)"#mixed": ["text", { "b": "bold" }, " more"]
Repeated elementArray – consistently for that path in the whole document