UltKit

JSON to XML Converter

Hand JSON data to software that only speaks XML. Each record turns into an element, each key into a child tag, and the whole document sits under one root element whose name you choose.

Data Converter

or drop CSV, TSV, TXT … files here ·

Max 95 MB per file· Up to 20 files· Deleted after 30 minutes

Output

Files are processed on our servers and deleted after 30 minutes.

How to use this tool

  1. 1

    Upload the JSON

    Add a .json file, such as an API response, or a JSON Lines file. Up to 20 files, 95 MB each.

  2. 2

    Name the root element

    Under Advanced settings, type the outer tag into XML root tag (it starts as rows) and leave Pretty print on for indented output.

  3. 3

    Convert and map

    Press Convert to XML and download. Rename tags where the receiving system's schema expects different names.

Why convert JSON to XML when most APIs moved to JSON

JSON won the web API; its current specification, RFC 8259 from 2017, fits on a few pages. XML is older, a W3C Recommendation since February 1998, and it never left the places where contracts are strict: banking, e-invoicing, publishing and government reporting.

So the direction of this conversion usually follows money or regulation. A developer pulls orders from a JSON API and has to post them to a partner's SOAP service. A shop keeps products in JSON but the comparison site wants an XML feed. A team stores translations as JSON and an Android build expects strings.xml. When the destination is a spreadsheet instead, JSON to CSV gives you rows rather than elements.

Systems that still expect XML input

Where a JSON to XML converter gets used
OrganisationRequirementSource
SOAP web servicesEvery request travels as an XML envelope; SOAP 1.2 became a W3C Recommendation in 2003—
Google Merchant CenterProduct feeds accepted as XML in RSS 2.0 or Atom 1.0, as well as delimited text—
Peppol e-invoicingInvoices exchanged as UBL 2.1 XML documents under the Peppol BIS Billing 3.0 rules—
Android appsText resources and translations live in res/values/strings.xml—

JSON to XML example: two products

XML written from [{"sku":"A-17","price":12.5,"tags":["new","sale"]}, {"sku":"B-02","price":8}]
<?xml version="1.0" encoding="UTF-8"?>
<rows>
  <row>
    <sku>A-17</sku>
    <price>12.5</price>
    <tags>new</tags>
    <tags>sale</tags>
  </row>
  <row>
    <sku>B-02</sku>
    <price>8</price>
  </row>
</rows>

MythJSON and XML map one to one, so the conversion is exact.

FactXML has attributes, mixed content and namespaces that JSON lacks, and JSON has types XML lacks. A converter has to pick one mapping; this one uses child elements throughout.

MythThe number 12.5 stays a number in the XML.

FactXML stores characters. 12.5 is text until a schema or the reading program says it is a decimal.

What changes when JSON becomes XML

Three things deserve a check. Types flatten to text, so true, null and 0 all arrive as characters; a null usually becomes an empty element. Keys that are not legal XML names have to be renamed, since a tag cannot begin with a digit or contain a space. And the output is larger, because every value is wrapped in an opening and closing tag that repeats the key.

Nothing else is lost. Nesting survives as nested elements, the order of records is kept, and Unicode text stays intact because the file is written in UTF-8. More options for structured data, from YAML to SQL, are listed on the data converter page.

JSON and XML format facts

JSON

JavaScript Object Notation

JSON is a lightweight text format for structured data, popularised by Douglas Crockford in the early 2000s and standardised as RFC 8259 and ECMA-404. It represents objects, arrays, strings, numbers, booleans and null with simple, readable syntax. It is the default format for web APIs, configuration files and data exchange between apps in almost every programming language. It has no comments, dates or schemas built in, and large nested files are hard to read without a viewer.

Compression
–
Transparency
–
Animation
–
Introduced
2001 · Douglas Crockford
JSON converter

XML

Extensible Markup Language

XML is a markup language for structured data published by the W3C in 1998. It uses nested tags with attributes and supports schemas, namespaces and validation, which makes it robust for complex documents. It underlies RSS feeds, SVG, Office documents, sitemaps and many enterprise and government data exchanges. XML is verbose compared with JSON, but every programming language and many spreadsheet tools can read it.

Compression
–
Transparency
–
Animation
–
Introduced
1998 · W3C
XML converter

JSON is converted to XML when modern data has to enter an older contract: a SOAP endpoint, a product feed, an e-invoicing network or a config file whose consumer was written to parse elements, not braces.

JSON to XML converter FAQ

Why does XML need one root element when my JSON starts with an array?

The XML 1.0 specification requires every well-formed document to have exactly one element that contains everything else. A JSON array has no such wrapper, so the converter adds one, named by XML root tag, and places each array item inside it as a <row>.

What happens to JSON keys like "2024 total" or "unit price"?

Neither is a legal XML element name: names cannot start with a digit or contain spaces. Rename such keys in the JSON before converting, ideally to the exact tag names the receiving schema uses, so the output needs no cleanup afterward.

How is a JSON array inside a record written in XML?

As the same element repeated once per item. A tags array with three strings becomes three <tags> elements in a row. An empty array leaves nothing behind, which is one of the few places where JSON to XML loses information.

Will the XML pass my partner's XSD validation?

Only if the structure already matches. The converter writes a faithful, well-formed copy of your JSON; it cannot know a partner's required element order, namespaces or attributes. Use the output as the starting point and adjust it to the schema.

Can I go from XML back to JSON?

Use XML to JSON. Expect small differences on the round trip: XML stores every value as text, so a number or true that started in JSON may come back as a string.