XML to JSON Converter
Paste XML and convert it to JSON instantly. Attributes become an "@attributes" object; everything runs in your browser.
XML Input
JSON Output
XML to JSON conversion maps each element to a JSON object, with attributes collected under an @attributes key and repeated sibling elements collapsed into arrays automatically.
Frequently asked questions
How do I convert XML to JSON online?
Paste your XML into the input box and click Convert. The converter parses it with the browser's XML parser and outputs indented JSON instantly.
How are XML attributes represented in the JSON output?
Attributes are collected into an "@attributes" object on the corresponding JSON node, keeping them separate from child elements and text content.