YAML to JSON converter (and JSON to YAML)
Paste YAML to get JSON, or switch direction to turn JSON into YAML. Conversion happens in your browser; nothing is uploaded.
What is supported
The YAML reader handles the parts used in most configuration files: nested mappings and lists by indentation, flow lists and mappings such as [a, b] and {x: 1}, single and double quoted strings, comments, null, true and false, integers and decimals, and block text with | and the greater-than sign. It follows YAML 1.2 rules, so words such as yes, no and on stay text and an exponent such as 3.14e2 is read as a number. It does not support anchors and aliases, tags, several documents in one file, or keys that are not plain text, and it stops with an error message instead of guessing when it meets them. In JSON output, mapping keys are always strings, and integers of more than 15 digits are kept as text to avoid losing precision. For checking or reformatting plain JSON, see the JSON formatter and validator.
