FreeConvert1PDF, document and archive tools
Tool index A–Z

YAML to JSON

Turn a YAML settings or data file into JSON for a script, an import or a form that only takes JSON. If the YAML is broken, the page tells you the line and column where reading stopped, which makes it a quick checker before you hand a file over.

Choose files
or drop them here
YAML · YML · folders work too
Processed on your device: your files are never uploaded.No sign-upNo watermarkNo daily limitNo queue

How to convert YAML to JSON

  1. Pick the .yaml or .yml file.
  2. Choose indentation for the JSON, or None for a single compact line.
  3. Convert. An error message points at the line to fix.

How values are interpreted

The file is read with the YAML 1.2 core rules. That keeps yes, no, on and off as words, keeps a date such as 2026-10-28 as text rather than a timestamp, and reads 0755 as the number 755. Only true and false become booleans, and null or an empty value becomes null.

Repeated blocks defined once with an anchor (&name) and reused with an alias (*name) are written out in full at each place they are used. Comments are not carried over, because JSON cannot hold them.

Files with more than one document

A YAML file can hold several documents separated by --- lines. When there is more than one, the JSON is a list with one entry per document, in the same order; empty documents are left out. A file with one document produces that document on its own.

Anchors only work inside the document that defines them. Using one from an earlier document stops the conversion with an "unidentified alias" message and the line number.

Typical mistakes it catches

Most YAML errors are indentation: a key one space further in than its neighbours, or a tab used instead of spaces, which YAML forbids. You also get clear messages for a missing space after a colon and for quotes that are opened but never closed.

Only the first error is reported each time. Correct it, convert again, and repeat until the JSON downloads.

Questions

Why does my CloudFormation file fail?

Tags such as !Ref and !Sub are specific to AWS and not part of standard YAML, so the reader reports an unknown tag.

Does anything leave my computer?

No, the YAML is read and converted in the browser.