XML to JSON
Convert XML to JSON and JSON to XML online for free. Paste your XML data and get formatted JSON output instantly. Handles nested elements and attributes.
Runs entirely in your browser — files never uploaded
XML → JSON
DOMParser is not defined
How to use XML to JSON
- 1. Paste XML. Paste or type your XML document in the left pane.
- 2. View JSON. The converted JSON appears instantly in the right pane.
- 3. Copy or switch direction. Copy the output, or toggle to JSON-to-XML mode to convert the other way.
FAQ
Does it handle attributes?
Yes. XML attributes are converted to keys prefixed with @ (e.g. @id).
What happens with repeated child elements?
Multiple children with the same tag name are automatically grouped into a JSON array.
Can I convert JSON back to XML?
Yes. Use the direction toggle to switch to JSON-to-XML mode.
Is my data uploaded?
No. Everything runs entirely in your browser.
Related tools
- Base64 EncoderEncode text or files to Base64 or decode Base64 back online for free. Instant conversion, no signup, runs in your browser.
- JSON FormatterFormat and validate JSON online for free. Beautify with indentation, validate syntax, or minify. Runs in your browser, no signup.
- CSV ↔ JSONConvert CSV to JSON or JSON to CSV online for free. Live preview as you type or upload a file. No signup, runs in browser.
- Timestamp ConverterConvert Unix timestamps to dates and dates to timestamps online for free. Supports seconds, milliseconds, ISO 8601. No signup.
- JWT DecoderDecode JWT tokens online for free. Inspect header, payload, and claims. Verify expiration and signature algorithm. No signup, runs in browser.
- Regex TesterTest regular expressions online for free with live match highlighting, capture groups, and flag toggles. Supports JavaScript regex. No signup.
Advertisement