JSON ↔ YAML Converter
Paste JSON or YAML: the conversion appears live, with the exact line of the error if the content is invalid. Nothing is sent to a server.
Conversion
About JSON and YAML
JSON and YAML describe the same data: objects, lists, strings, numbers, booleans. JSON is the format of APIs and package.json files; YAML, more readable and with comments, is used by Docker Compose, Kubernetes, GitHub Actions, Ansible and OpenAPI.
Features
- Both ways: JSON → YAML and YAML → JSON, “Swap” button
- Indentation of 2 or 4 spaces, optional key sorting
- Multiple documents: a YAML file with “---” becomes a JSON array
- Precise errors: line and column of the problem
- Safe parsing: no executable types, dates stay as text
- Copy or download the result (.json, .yaml)
How to use
- Step 1: choose the conversion direction
- Step 2: paste your content in the left-hand box
- Step 3: copy or download the result
Good to know
- YAML comments (#) do not exist in JSON: they are lost in conversion
- Strings such as “yes”, “no”, “on” or “08” are quoted in YAML so they are not read as booleans or numbers
- YAML anchors and aliases (&, *) are expanded in the JSON
Privacy
Everything is computed in your browser: the data you enter is never sent anywhere and we never have access to it. Internal data can be pasted safely.