YAML ↔ JSON Converter
Convert between YAML and JSON.
Usage examples
Moving a config file to a different format
Convert a YAML config, like a Docker Compose or GitHub Actions file, before pasting it into a tool that only accepts JSON.
Turning a JSON API response into readable YAML
Convert a brace-heavy JSON response into indentation-based YAML so the structure is easier to scan at a glance.
Quickly spotting a YAML syntax error
Paste in YAML broken by an indentation or colon mistake and see exactly what's wrong from the error message.
Frequently asked questions
Is what I enter sent to a server?
No. All conversion happens entirely in your browser, and what you enter is never sent to a server.
Does it support complex YAML, like anchors or multiple documents?
It supports most of standard YAML 1.1/1.2, including anchors and aliases. Just keep a single document in the input.
What happens to values JSON can't represent, like undefined?
JSON can't represent values like undefined or functions, so avoid including them in the input before converting. Ordinary strings, numbers, booleans, arrays, objects, and null all convert fine.
Is the original indentation and line breaks preserved?
The output is freshly generated using the library's default formatting, so original comments or specific line-break styles aren't preserved.