YAML to JSON
Paste YAML, get JSON. Anchors and aliases are resolved. The reverse direction is at JSON → YAML. YAML 1.2 first-class; for older 1.1 inputs with the Norway problem (NO → false), wrap such values in quotes before pasting.
Paste YAML.
How to convert YAML to JSON
- Paste in either panel — the tool auto-detects direction.
- Output appears in the opposite panel live. The Swap button flips them, useful for round-tripping.
- YAML output options: Block style (default — readable), Flow style (compact, JSON-like), Quote style (auto / single / double).
- Copy or Download as
.yaml/.yml/.json.
Common pitfalls
- Anchors and references — resolved into JSON (which has no equivalent). Round-tripping back to YAML inlines them.
- Multiple documents (
---separators) — JSON has no document concept; only the first is parsed. Use NDJSON for streams. - Complex keys (objects as keys) — JSON disallows; the tool reports an error.
FAQ
Is YAML 1.1 supported?
The parser is YAML 1.2 — most 1.1 docs parse fine, but the Norway problem and the !!str / !!int tag handling differ. If a 1.1 doc fails, quote ambiguous scalars.
What about comments?
JSON has no comments. They're stripped during conversion. Use the round-trip back to YAML to re-author with comments.
Will it work offline?
Yes.