Free · runs in your browser · no upload · no quota
JSON to YAML Converter
Convert JSON into clean, readable YAML — the format of Kubernetes manifests, Docker Compose files, GitHub Actions and most configuration files. The page validates your JSON first and points to the line of any error.
How to Convert JSON to YAML
- Add your JSON
Paste it into the left box or open a .json file. Invalid JSON is reported with its line and column. - Pick the indentation
Two spaces is the YAML convention; choose four if your project uses it. - Copy or download the YAML
Copy the result, or click Download to save a .yaml file.
Example
{
"service": "web",
"ports": [80, 443],
"env": {"DEBUG": false}
}service: web ports: - 80 - 443 env: DEBUG: false
Frequently Asked Questions
-
Is every JSON file valid YAML?Yes — YAML 1.2 is a superset of JSON, so the data converts without loss. This tool writes it in YAML's block style, which is what people usually mean by YAML.
-
Are strings like "yes", "no" or "08" kept as strings?Yes. Values that a YAML reader could mistake for a boolean, number or date are quoted, so the YAML reads back exactly as the JSON was.
-
Why does it say my JSON is invalid?JSON does not allow trailing commas, comments or single quotes. The error message gives the position of the first problem.
-
Is anything uploaded?No. The conversion runs entirely in your browser.