YAML to JSON Converter
Convert YAML to JSON or JSON to YAML, with clear error messages for broken files.
How to use the YAML to JSON Converter
- Pick a directionChoose YAML → JSON or JSON → YAML.
- Paste your dataPaste a config file or open a .yaml, .yml or .json file.
- Copy the resultCopy or download it. Errors show the exact line and column.
Example
server: →
port: 8080{"server": {"port": 8080}}
Going back, {"features": ["search", "cart"]} becomes a YAML list with one item per line.
Frequently asked questions
What is the difference between YAML and JSON?
They store the same kind of data. JSON uses braces, brackets and quotes and is common in APIs. YAML uses indentation and is easier to read, so it is popular for config files like Docker Compose, Kubernetes and GitHub Actions.
Are comments kept?
No. JSON has no comments, so YAML comments are dropped when converting to JSON.
Can it handle several YAML documents in one file?
Yes. Documents separated by --- are converted into a JSON array, one item per document.
Is my file uploaded?
No. The conversion runs in your browser.