Why convert YAML to JSON?
YAML is friendly for humans writing config files; JSON is what APIs, browsers and most programming tools actually speak. Converting between them is a daily task for developers moving Kubernetes, CI/CD, Docker Compose or application config into a JSON pipeline. This YAML to JSON converter handles the common cases — key-value pairs, nested objects, lists, lists of objects, numbers, booleans, nulls, quoted strings and simple inline flow collections — and formats the result with clean two-space indentation.
How to use this converter
- Paste your YAML into the top box (or edit the sample that is pre-loaded).
- The JSON appears in the output box as you type; click "Convert to JSON" any time to re-run it.
- If something is wrong, the error message names the line and the problem — usually a stray tab or uneven indentation.
- Copy the JSON with one click.
What is supported (and what is not)
Supported: nested maps, sequences, sequences of maps, scalars (strings, integers, floats, booleans, null), single- and double-quoted strings, comments, and one-line flow collections like [1, 2, 3]. Not supported: multi-line block strings (| and >), anchors and aliases (& / *), custom tags, and multi-document files. For those, use a full YAML library such as js-yaml or Python's PyYAML. And because the conversion runs entirely in your browser, your config — secrets and all — never leaves your machine.