Your files stay on your device

YAML formatter, validator, converter

Check YAML with positioned errors, reformat it, or walk it to and from JSON through the shared interchange model: anchors resolved away, merge keys expanded, comments counted as dropped, every loss in the report.

YAML

Paste, type, or drop a file

Result

Loading editor…

Anchors, aliases, and merges

YAML lets you name a block once and reuse it. The &name marks an anchor, *name pulls in a copy of that node, and << merges a mapping into the current one. Merges are a widely supported extension rather than part of the core YAML 1.2 spec, so not every parser accepts them.

&baseanchor on the node that follows
*basealias that reuses the anchored node
<<: *basemerge the anchored mapping into this one

Unquoted yes and no

YAML 1.1 reads unquoted yes, no, on, and off as booleans. A country list with NO for Norway parses as false. YAML 1.2 narrows booleans to true and false, but plenty of tools still follow the older rules. Quote a value like 'NO' when the text is meant to stay a string.

What JSON cannot hold

JSON has no comments and no anchors. Converting to JSON therefore resolves each alias into its value, so repeated data is written out in full. Comments have nowhere to go, so the report lists each one as dropped. Read that report before you trust the converted file.

Was this tool useful?