KERVONI · FREE TOOL

XML to JSON Converter

Convert XML locally to an ordered JSON tree. Preserve attributes, namespaces, repeated elements and text values without uploading.

JSON tree output uses type/name/namespace/attributes/children. Repeated elements and mixed text keep their order; text and attribute values stay strings.

XML 1.0, up to 64 KiB UTF-8, 2,000 nodes, 32 levels and 128 attributes per element. No DTD or custom entities.

XML parsing normalizes line endings and attribute whitespace and resolves standard character references. This is not byte-for-byte XML preservation or compact grouped-object JSON.

Your XML is processed on this device. This tool does not upload or save it.

Trust & Help Centre →

Save this page in your browser bookmarks to use it again.

About this tool

Convert one XML 1.0 document to a JSON tree with type, name, namespace, attributes and children. Values remain strings, including IDs and large numbers. Repeated elements, mixed text, CDATA and comments retain their order. Up to 64 KiB UTF-8; DTD and custom entities are rejected.

Free without an accountLocal browser processingNo input upload

How to use

  1. Paste one XML document or load the example.
  2. Convert, inspect the JSON tree, then copy or download converted.json. Editing the input clears the previous result.

Example

<order id="00123"><item>9007199254740993</item></order> keeps the attribute and item text as strings.

Frequently asked questions

Why is the JSON an ordered tree?

JSON tree output uses type/name/namespace/attributes/children. Repeated elements and mixed text keep their order; text and attribute values stay strings. XML parsing normalizes line endings and attribute whitespace and resolves standard character references. This is not byte-for-byte XML preservation or compact grouped-object JSON.

Do I need an account?

No. This free tool can be used without creating an account.

Where is my input processed?

This tool processes its input in your browser. Tool input is not uploaded for processing. General site usage statistics are separate; see the privacy policy.