JSON to YAML Converter
Turn JSON into YAML, the easy-to-read format used for configuration files, deployment settings and content front matter. The result uses clean indentation, adds quotes only where they are needed and keeps every value exactly.
How to Convert JSON to YAML
Quick answer: paste your JSON or open a .json file; the YAML appears below. Download it as .yaml or copy it.
-
1
Add your JSON
Paste it or open a .json file.
-
2
Pick indentation
2 or 4 spaces.
-
3
Sort keys if wanted
Alphabetical order.
-
4
Download .yaml
Or copy it.
What You Get
Why Convert JSON to YAML?
YAML describes the same data as JSON, but without braces, brackets and most quotes, so it is much easier for people to read and edit. That is why it is the usual format for configuration files, deployment and automation settings, documentation front matter and many developer tools. If your settings or data are in JSON, converting them to YAML gives you a file that is ready to drop into those tools.
How the Conversion Works
Objects become indented key: value lines, arrays become lists with a dash in front of each item, and numbers, true, false and null keep their types. Strings are written without quotes whenever that is safe, and quoted when they could be misread, such as text that looks like a number, contains a colon followed by a space, or starts with a special character. "enabled: yes" in the sample is therefore quoted so it stays text.
Indentation and Sorting
Two spaces is the most common YAML style; four spaces can be easier to read in deep structures. Some projects require one or the other, so pick the one your tool expects. Sort keys puts the keys of every object in alphabetical order, which makes large configuration files easier to compare and review.
Example
The sample becomes:
app: shop
version: 3
debug: false
servers:
- name: web
port: 8080
… with the checkout value quoted. To go back, use YAML to JSON.
Who Converts JSON to YAML?
Developers turning settings into configuration files, operations teams writing deployment and automation files, writers adding front matter to articles, and anyone who received data as JSON but needs to edit it comfortably. YAML's readability makes reviews and edits much less error-prone.
Step by Step
Paste your JSON or open a .json file. If the JSON is invalid, fix the problem shown in the message; the JSON Formatter helps. Choose the indentation, decide whether to sort keys, then download the .yaml file or copy the text into your project.
Good to Know
YAML is sensitive to indentation: use spaces, never tabs, when you edit the result. Comments are not part of JSON, so the YAML has none; you can add lines starting with # afterwards. Very long strings are kept on one line so nothing is changed. Every value converts back to exactly the same JSON.
Real-World Scenarios
You have a settings object from an app or a service response and want to keep it in a configuration file that people will edit by hand. Convert it to YAML here, sort the keys for easier reviews, and save it as a .yaml file. Writers with static site generators turn JSON metadata into front matter for their pages. Teams moving from JSON to YAML configuration convert their existing files in a few seconds each, check the result, and commit it, instead of retyping long settings and risking mistakes along the way.
Private, Free and Instant
The converter is free and works with files up to 5 MB. There is no sign-up, no row limit beyond the 5 MB file size and nothing to install. The conversion runs in your browser, so customer lists, exports, settings files and other private data are never uploaded or stored. You can open a file from your device, paste data straight from another program, and download the result with the right file extension. It works on Windows, Mac, Linux, Chromebooks, iPhone and Android.
JSON to YAML: Making Data Human-Friendly
YAML is a superset of JSON in practice, but written with indentation, no braces and optional quotes, which makes it easier to read and edit.
What to expect
Objects become key-value lines, arrays become dashed lists and strings are quoted only when needed. Comments cannot come from JSON, but you can add them afterwards.
Caution
Indentation is meaningful in YAML. Use spaces, never tabs. For the other direction, see YAML to JSON.
Frequently Asked Questions
Questions about JSON to YAML