JSON to YAML Converter

Turn JSON into clean block-style YAML.

name: AllFreeTools
free: true
tags:
  - calculator
  - converter
owner:
  country: India

Produces plain block-style YAML. Strings that could be misread, such as "true" or "12:30", are quoted.

About this tool

YAML is a readable format used for configuration in tools such as Kubernetes, GitHub Actions and Docker Compose, while data often starts life as JSON. This converter turns JSON into block-style YAML with two-space indentation. Objects become key and value lines, arrays become dash lists, and nested structures are indented. The tool is careful about quoting, because plain YAML can misread text: a string such as true, null or 12:30 pm would be read as a boolean, a null or a time if left bare, so those are written in double quotes, as are empty strings and strings with line breaks. Numbers and real booleans stay unquoted. If your JSON is invalid, the tool shows the parser's message instead of guessing. Conversion runs in your browser, so configuration that includes names, hosts or other private details is not uploaded anywhere. The output is plain YAML without comments or anchors.

How to use it

  1. Paste your JSON into the input box.
  2. If you see an error, fix the JSON using the message shown.
  3. Read the YAML in the result panel.
  4. Check that quoted values look right for your tool.
  5. Copy the YAML with the copy icon.

How it works

Each object key becomes key: value on its own line and nested values are indented by two spaces. Array items start with a dash. Empty arrays and objects are written as [] and {}. Strings are quoted with JSON-style double quotes when they are empty, contain characters that YAML treats specially, look like true, false, null or yes and no, or end with a space.

Example: The JSON {"name":"AllFreeTools","free":true,"tags":["a","b"]} becomes name: AllFreeTools, free: true and then tags: followed by two indented lines, - a and - b.

Common uses

  • Converting a JSON settings file into YAML for a deployment tool.
  • Writing a CI workflow or compose file from data you already have as JSON.
  • Reading nested JSON more easily by viewing it as YAML.

Frequently asked questions

Why are some strings in quotes?
Plain YAML can misread text such as true, null or 12:30. Quoting keeps it as a string, which is what the JSON meant.
Does it keep key order?
Yes. Keys appear in the same order as in the JSON.
Can it convert YAML back to JSON?
Not in this version. It converts JSON to YAML only.
Does it add comments or anchors?
No. The output is plain YAML with no comments, anchors or tags.
Is my JSON uploaded?
No. Your JSON is parsed and converted by your browser, and the page has no code that sends it to a server.

Last reviewed 2026-11-01. Browse all tools