JSON ↔ YAML Converter

Convert between JSON and YAML in both directions, with validation.

Paste JSON or YAML, then pick a direction. Ctrl/⌘ + Enter repeats the last direction.

What this tool does

Paste JSON on the left and press "JSON → YAML" to get clean, indented YAML; paste YAML and press "YAML → JSON" to get pretty-printed JSON. The converter uses a full YAML 1.2 parser, so it understands block and flow styles, multi-line strings, anchors and aliases, and reports the exact line and column of any syntax error. Choose 2 or 4 spaces of indentation, and turn on "Sort keys" to order object keys alphabetically at every level, which makes two files easy to compare.

Things to know

Privacy

The conversion runs in your browser. Nothing you paste is uploaded or stored, so configuration files with secrets are safe to convert here.