JSON to XML converter

Convert JSON objects and arrays to well-formed XML. Specify a custom root element tag. Download output as an .xml file. Runs entirely in your browser.

JSON input

XML output

How JSON to XML conversion works

JSON objects become XML elements. Object keys become child element tag names. Arrays produce repeated elements (with the parent key singularised). Primitive values (strings, numbers, booleans) become text content.

API access

POST /api/v1/datatools/convert/json-to-xml — body: {"input":"...json...","rootTag":"root"}

What happens with JSON arrays? +
Array items are wrapped in child elements using the parent key name (with trailing 's' removed). For example, "users": [...] produces repeated <user> elements inside a <users> wrapper.