Convert JSON to well-formed XML, or parse XML back into JSON — instantly in your browser.
The JSON → XML path parses your input with JSON.parse, then walks the object recursively. Each key becomes an XML element, arrays repeat the element tag (or use <item>), and primitives become text content. Special characters (&, <, >, ") are escaped so the result is well-formed. The XML → JSON path uses DOMParser to build a DOM tree, then reduces it: text-only nodes become string values (auto-coerced to numbers, booleans, or null when possible), and repeated sibling tags collapse into arrays. A single wrapper root element keeps the output valid JSON.
No. All parsing and conversion happens locally in your browser using JavaScript. Nothing is uploaded, which makes it safe for sensitive or private payloads.
Yes. Switch to the XML → JSON tab, paste your XML, and click Convert. The tool parses the DOM and produces a compact JSON representation, collapsing repeated tags into arrays automatically.
By default, each array entry becomes a repeated element with the parent key as its tag. You can customise the root tag in the options, and primitives, objects, and nested arrays are all handled recursively.