Data Conversion Suite · free · no sign-up
XML to JSON
Convert XML into JSON for use in JavaScript and APIs.
XML to JSON Converter
Transform XML documents into structured JSON with attribute & element handling
β‘ Nested Support
π Attributes
π Pretty Print
About the XML to JSON
Convert XML into JSON for use in JavaScript and APIs.
How to use the XML to JSON
- Paste your XML or click Sample.
- Choose the Indentation and the Attribute Handling (prefix with @, nest in _attr, or ignore), and optionally Force Arrays.
- Press Convert to JSON and copy the result.
Tips
- Force Arrays keeps the structure consistent when an element may appear once or many times.
Frequently asked questions
What happens to XML attributes?
You choose: prefix them with @, nest them in an object, or drop them.