JSON to XML Converter

Convert JSON to XML for free — paste JSON or open a file and get well-formed XML instantly. Arrays repeat the element, keys starting with @ become attributes, “#text” becomes element text, special characters are escaped and invalid element names are made safe. Choose the root and array item names, indentation, and whether to add the XML declaration.

100% private — everything runs in your browser. Conversion happens on your device; nothing is uploaded.

100% private — runs in your browser

Keys starting with the attribute prefix become XML attributes, “#text” becomes element text, arrays repeat the element, and special characters are escaped. Invalid element names are made safe automatically. Runs in your browser.

How to convert JSON to XML

  1. Paste your JSON or click Open file.
  2. Set the root and item names if your JSON needs them.
  3. Pick the indent or minified output.
  4. Copy the XML or download the .xml file.

What you can use it for

  • Feed JSON data into XML-only systems and SOAP APIs
  • Create XML config and data files
  • Build RSS-style or sitemap XML from JSON
  • Round-trip data converted with XML to JSON

More free tools

Building for the web?

Format, minify, convert and generate code with our free, private developer tools.

See all free tools →

Frequently asked questions

How do I make XML attributes from JSON?

Prefix the key with @ — {"book": {"@id": "bk101"}} becomes <book id="bk101"/>.

What happens to JSON arrays?

Each item becomes a repeated element with the array's key as its name. A top-level array is wrapped in the root element with “item” elements (you can rename both).

Does it escape special characters?

Yes — &, < and > are escaped in text, and quotes too in attributes, so the XML is always well-formed.

Is my data uploaded?

No. It's converted in your browser — nothing is sent to a server.