Converters
YAML to JSON
Some tools and APIs only accept JSON even when your configuration lives in YAML. The YAML to JSON converter parses your YAML — including nested maps, lists and multi-line strings — and outputs pretty-printed JSON.
It also doubles as a YAML validator: if the indentation is wrong, you get an error instead of silent data loss.
How to use the YAML to JSON
- 1Use the YAML to JSON right on this page, or open the full workspace for history, sharing and every other tool.
- 2Paste your input, upload a file, or drag and drop a file onto the input box (up to 25 MB).
- 3The result appears in the output panel automatically and updates when you change the input or an option.
- 4Use Copy Output or Download to save the result. Nothing is uploaded to a server.
Example
A YAML document with a list of skills becomes a JSON object with an array.
Input
name: Ada skills: - math - logic
Output
{
"name": "Ada",
"skills": [
"math",
"logic"
]
}When to use it
- Feeding a YAML config into a JSON-only API or script
- Checking how a YAML file is actually interpreted by a parser
- Converting OpenAPI specs from YAML to JSON
Tips and common mistakes
- Unquoted yes/no values may become booleans — the JSON output shows exactly what was parsed.
- Tabs are not allowed in YAML indentation.
- Anchors and aliases are expanded into full values in the JSON output.
Frequently asked questions
Does it support comments in YAML?
Yes, comments are allowed in the input; they are dropped because JSON has no comment syntax.
Is the output minified?
No, it is indented. Use the JSON Minifier if you need it compact.