JSON to YAML converter

Paste JSON and get the YAML version straight away. Invalid JSON gives a message with the line and character where it goes wrong. Copy the result or download it as a .yaml file.

Indent
Quotes (where needed)

How it works

  1. Paste your code

    Paste the code in the left box or open a file. No code to hand? Click Example.

  2. Instant result

    The result appears as you type. If there is an error, you see the line and character.

  3. Copy or download

    Copy the result with one click or save it as a file for your editor or project.

Why YAML?

YAML holds the same data as JSON, but without braces and most quotes, and with indentation instead of brackets. That makes it nicer to read and edit by hand. Configuration files for Docker Compose, Kubernetes, GitHub Actions, Home Assistant and Ansible are written in YAML.

When are there quotes?

Only where they are needed. Text such as true, 123 or yes: no would mean something else in YAML than in your JSON, so it is quoted. That way the result is exactly the same when you convert it back with YAML to JSON.

Frequently asked questions

Is the JSON to YAML free?

Yes. The JSON to YAML is completely free, with no account, sign-up or usage limit.

Is my code stored?

No. Your code is processed in your browser and is not sent to a server or stored.

Does it work on my phone?

Yes. The tool works in any modern browser on a phone, tablet or computer.