Skip to content
Your data never leaves your browser

XML to JSON

Angle brackets in, curly braces out.

Input
Output

What this does

DEVS: DOMParser to recursive JSON. Attributes go to @attributes, text content to #text. Client-side only.

Paste XML, get JSON. Elements become object keys. Attributes are preserved. Duplicate sibling elements collapse into arrays.

Common use cases

Consuming SOAP API responses in a modern stack. Migrating XML config files to JSON equivalents. Parsing RSS or Atom feeds for JavaScript apps.

Things to know

XML attributes go under an @attributes key. Text content goes to #text. Namespaces are preserved in element names but aren't given special treatment. Comments and processing instructions are dropped.

Privacy

Parsed and converted entirely in your browser. Your XML never leaves your machine.