JSON to XML converter
Paste JSON and get indented XML with a declaration, ready for systems that only accept XML.
Private: everything happens in your browser. Nothing you type or choose is uploaded.
{
"order": {
"@id": "1001",
"customer": "Ada",
"item": ["Notebook", "Pen"],
"paid": true
}
}How to use it
- Paste your JSON.
- Set the root element name if your JSON has more than one top-level key.
- Copy the XML.
Questions and answers
How are arrays converted?
Each item becomes an element with the array’s name, for example two <item> elements.
How do I make an attribute?
Start the key with @, for example "@id": "1001" gives id="1001".
What happens to keys that are not valid XML names?
Spaces and symbols become underscores, and a name that starts with a digit gets a leading underscore.