J→Y

JSON to YAML

Convert JSON into readable YAML, with block or compact flow style.

json-to-yaml.tool
0 chars
YAML output will appear here
Nothing you paste here is ever sent to a server - conversion happens locally in your browser.
Overview

What is a json to yaml?

This tool converts JSON into YAML - handy when a tool or config format expects YAML but you're working with JSON data. It supports both YAML's readable block style (the default, one key per line) and a compact flow style closer to JSON's own bracket syntax.

Quick start

How to use this tool

  1. 1Paste your JSON, or upload a .json file.
  2. 2Toggle Compact (flow) style if you want a denser, single-line-per-object output instead of the default multi-line block style.
  3. 3Click Convert.
  4. 4Copy the YAML or download it as a .yaml file.
Where it helps

Common use cases

Turning a JSON API response into a YAML config file
Preparing YAML for a CI/CD pipeline or Kubernetes manifest from JSON data
Converting JSON test fixtures into more human-readable YAML
Documenting a JSON structure in a more compact, readable format
Good to know

Frequently asked questions

What's the difference between block and flow style?

Block style (the default) spreads keys and list items across multiple lines with indentation - the style most people associate with YAML. Flow style packs everything into brackets and braces on fewer lines, closer to JSON's own syntax.

Does it preserve number and boolean types?

Yes - numbers, booleans, and null in the JSON are written as their native YAML equivalents, not quoted strings.

Why are some string values quoted in the output?

YAML quotes strings that could otherwise be misread as another type - for example a key or value like "y" or "true" gets quoted so it stays a string rather than being interpreted as a boolean.

Is my JSON uploaded anywhere?

No - conversion happens entirely in your browser, whether you paste the JSON or upload a file.

quick_facts.json

{

"runs_in_browser": true,

"data_sent_to_server": false,

"signup_required": false,

"price": "free",

"category": "Encoding"

}

Related tools

B64
No signup
Base64 Encoder

Encode text to Base64, with correct Unicode handling.

Open tool
B64
No signup
Base64 Decoder

Decode Base64 back to readable text, with correct Unicode handling.

Open tool
URL
No signup
URL Encoder

Percent-encode URLs and query strings, component or full-URI mode.

Open tool