</> Format Swapper

JSON · XML · CSV · YAML — convert between any of them

Input
Output

JSON, XML, CSV & YAML at a glance

JSON is the default data-interchange format for REST APIs, config files, and NoSQL databases — nested objects and arrays, but no comments. XML is the format behind SOAP APIs, RSS/Atom feeds, Office file formats, and older enterprise data exchange — it supports attributes, mixed content, and namespaces that JSON has no equivalent for. CSV is the universal format for spreadsheets and data-analysis pipelines like Excel, Google Sheets, and pandas — inherently flat, so nested structures don’t exist natively. YAML is the format of choice for configuration — Kubernetes manifests, Docker Compose, GitHub Actions, Ansible playbooks — it supports comments and multi-document files that JSON doesn’t.

Nested structures flatten to CSV using dot-notation columns (address.city) and bracket-indexed columns for arrays (tags[0]); XML attributes map to "@name" keys in JSON and YAML. Every conversion here runs through that shared model, so round-tripping between any two formats stays lossless for typical data. Each conversion pair has its own dedicated page (linked above) with format-specific details and an FAQ — this page is the quick, pick-any-two version.

How to convert between any two formats

  1. Pick the source format on the left and the target format on the right, then paste your data into the left editor (or click sample to try example data).
  2. Click Convert. If something's off, the status line reports the exact line and column, and that line is highlighted in the editor.
  3. Click copy to copy the result, or download to save it as a file.

Example: JSON to XML

Input (JSON):

{
  "name": "Ada Lovelace",
  "role": "Mathematician",
  "active": true,
  "skills": ["math", "programming"]
}

Output (XML):

<?xml version="1.0" encoding="UTF-8"?>
<root>
  <name>Ada Lovelace</name>
  <role>Mathematician</role>
  <active>true</active>
  <skills>math</skills>
  <skills>programming</skills>
</root>

Frequently asked questions

Do I need to create an account? No. There's no signup, login, or account required — paste your data and click Convert.
Is there a file size limit? There's no hard-coded limit, but very large inputs (multi-megabyte files) can slow down or briefly freeze the tab while converting. For big files, converting in smaller chunks works better.
Why did my conversion fail? Check the status line under the Convert button — it reports the exact line and column where the parser stopped, and the input editor highlights that line in red so you can jump straight to it.