YAML to JSON

Convert YAML, such as a config file, into JSON as you type. Errors in the YAML show the exact line and column.

Your files stay on your device. Nothing is uploaded.

YAML to JSON

Converts as you type · files up to 20 MB

Step 1: Paste or open your YAML

Step 2: Options

JSON layout

Step 3: Copy or download

How to convert YAML to JSON

  1. Paste or open your YAML

    Paste YAML into the first box, or click Open a file. The conversion runs as you type.

  2. Choose the options

    Choose the JSON layout: 2 spaces, 4 spaces, tabs or one line.

  3. Copy or download

    Click Copy JSON, or Download .json for a file.

About this tool

How values are read

YAML's core rules are used: 42 and 3.5 become numbers, true and false become booleans, and null or ~ becomes null. Dates such as 2026-11-29 stay text, so they are not changed into a different time format.

Common YAML mistakes

YAML uses spaces for structure, never tabs, and items at the same level must line up exactly. A wrong indent is the most common error; the message points to the line.

Where YAML is used

Docker Compose, Kubernetes, GitHub Actions, OpenAPI files and many app settings are written in YAML. Converting to JSON helps when a tool or API only accepts JSON.

Privacy

This tool runs in your browser, on your own device. Your files and text are not uploaded to our server and we cannot see them. When you close or reload this tab, they are cleared, along with the results.

Frequently asked questions

Are comments kept?

No. JSON has no comments, so YAML comments are left out.

Does it support several documents in one file?

No, one YAML document at a time. Split documents separated by --- and convert them one by one.

Is my data sent anywhere?

No. The conversion runs in your browser.

Can I go back to YAML?

Yes, with JSON to YAML.