YAML to JSON Converter
Convert YAML to JSON and JSON back to YAML in your browser. Pick a direction, paste your text, and copy the result. Nothing is uploaded.
About the YAML to JSON Converter
The YAML to JSON Converter turns YAML into JSON and JSON back into YAML. Pick a direction, paste your text, and copy the result. It is handy for config files, CI pipelines, Kubernetes manifests, and API payloads where one format is expected but you have the other. Everything runs in your browser, so your data stays on your machine and is never uploaded.
How it works
- Choose a direction: YAML to JSON or JSON to YAML.
- Paste or type your text into the input area.
- Read the output, and pick an indent style (2 spaces, 4 spaces, or tab) to match your project.
- Click Copy to grab the result. If the input is invalid, the status bar shows where it failed.
Features
- Two directions: YAML to JSON and JSON to YAML.
- Handles maps, lists, nested blocks, inline flow style ([a, b] and {k: v}), quoted and plain scalars, comments, and null/boolean/number casting.
- Selectable indentation: 2 spaces, 4 spaces, or tab.
- Inline error messages when the input is not valid.
- One-click copy of the output.
Frequently asked questions
Is my data uploaded anywhere?
No. Both directions run entirely in your browser. Your YAML and JSON are never sent to a server or logged.
Which YAML features are supported?
The parser covers the common cases: block maps and lists, nesting by indentation, inline flow style such as [a, b] and {key: value}, single and double quoted strings, comments, and scalar casting for null, true/false, and numbers. Anchors, aliases, and tags are not supported.
Why does my YAML fail to convert?
The most common cause is inconsistent indentation, such as mixing tabs and spaces or uneven nesting. Check that each nested level uses the same number of spaces, and that list items line up under their parent key.
What indent does the output use?
You choose. The indent control offers 2 spaces, 4 spaces, or a tab, and it applies to whichever side is the output.
Does it work offline?
Yes. Once the page has loaded, conversion runs locally in your browser, so the tool keeps working without a connection.