XML to JSON Converter
Parse XML documents and convert them to equivalent JSON structure with attributes.
Attributes mapped as @_name, text content as #text
{
"catalog": {
"book": [
{
"@_id": "bk101",
"author": "Gambardella, Matthew",
"title": "XML Developer's Guide",
"genre": "Computer",
"price": "44.95",
"publish_date": "2000-10-01"
},
{
"@_id": "bk102",
"author": "Ralls, Kim",
"title": "Midnight Rain",
"genre": "Fantasy",
"price": "5.95",
"publish_date": "2000-12-16"
},
{
"@_id": "bk103",
"author": "Corets, Eva",
"title": "Maeve Ascendant",
"genre": "Fantasy",
"price": "5.95",
"publish_date": "2000-11-17"
}
]
}
}1 top-level key0.6 KB
How to Use XML to JSON Converter
- 1
Paste your XML
Enter the XML data you want to convert to JSON.
- 2
Convert instantly
See the JSON output generated automatically from the XML.
- 3
Copy the JSON
Click copy to grab the converted JSON output.
Related Tools
CSV to JSON Converter
Convert CSV data into structured JSON arrays or objects with automatic type detection.
JSON to CSV Converter
Transform JSON arrays and objects into downloadable CSV spreadsheet format.
YAML to JSON Converter
Convert YAML configuration files to JSON format with validation and formatting.
TSV to CSV Converter
Convert tab-separated values to comma-separated format with proper escaping.
Number Base Converter
Convert numbers between binary, octal, decimal, and hexadecimal bases.
Roman Numeral Converter
Convert between Roman numerals and Arabic numbers with validation.