Online YAML to JSON converter. Just paste valid YAML to get JSON.

YAML text input:
Result JSON:

What is YAML?

YAML is a text file .yaml or .yml extension that can be used as an alternative to JSON to store some data or configuration. YAML format is more readable than JSON and it's easy to maintain it by hand. There is a less visual noise in comparison to JSON because it uses spaces indentation to define nested structures. It makes sense to say about some extra YAML features like comments support and anchors/aliases that help to reuse data and don't Repeat Yourself (DRY).

How to use YAML to JSON converter?

Paste YAML text into the first text area. Click on "YAML to JSON" button to perform conversion. If your YAML is valid you will see its JSON representation in the second text area. If your YAML is invalid the conversion isn't possible. The error will be displayed right under the input. Click on "Paste JSON and YAML examples" to see the tool in action.

This is a YAML to JSON transformer. If you need to do an opposite operation please use JSON to YAML tool.

How to convert YAML to JSON in JavaScript?

You can install some popular NPM packages for it, for example yaml or js-yaml. Both of them are listed on the official YAML website.