XML / JSON

XML ↔ JSON converter

Convert XML to an ordered JSON structure, or encode JSON values as typed XML. Keep attributes, mixed text order and precise number text with explicit mappings.

Only this page link is shared. Your text, files and results are not included.

Use your browser to add this page to its bookmarks. This button shows the steps; it does not add a bookmark automatically.

Windows / Linux
Ctrl + D
Mac
⌘ + D

On your phone or tablet

Open your browser’s menu or Share menu and choose Add bookmark or Add to Favorites. In an in-app browser, open this page in your usual browser first.

Bookmarks save the page link, not your tool inputs or results. “Save as favorite” is a separate list within BIJJO.

Runs in your browser. Files are not uploaded.

XML / JSON

XML uses an ordered tree: element names, attribute arrays and ordered text/element/comment/CDATA children. XML text is kept as text, without guessing numbers or booleans.

Input up to 512 KiB UTF-8, output up to 4 MiB. Up to 10,000 nodes, nesting depth 40 and 100 attributes per element. Limits apply to both the source and generated structure.

Paste input or try the example.

How to use

Choose a direction. Paste input or load the example. For JSON → XML, choose regular JSON values or the ordered XML structure produced here. Convert, then copy or download the result. Use result as input switches direction with the correct mapping; it is available when the result fits the input limit.

Mapping and limits

Ordinary XML becomes a bijjo-xml-v1 JSON tree. JSON values become XML marked data-bijjo-format="json-v1"; converting that marked XML back restores JSON values and number text. These are documented mappings, not a universal XML/JSON standard. Namespaces, comments and CDATA inside the root are supported. XML declarations, material outside the root, entity spellings, quote style and original line-ending bytes are not preserved. The element name parsererror is reserved for detecting browser parse errors. Duplicate JSON keys are rejected. DTD, custom/external entities and processing instructions are unsupported. JSON strings with characters forbidden by XML 1.0 are rejected. Files are not uploaded or saved; input is parsed as data and never inserted into the page as HTML.