Skip to main content

Data

YAML Validator

Check whether YAML parses, and get the line number and the reason when it does not.

Written by · Published · Last updated

Runs in your browserPrivate by designYAML → TEXT
YAML→TEXT

Press ⌘ Enter to run

4 lines · 58 chars

Ready; press Run or ⌘ Enter

How this tool handles files

Processing
In your browser, on-device
Storage
Nothing stored
Output
A file you download
Your responsibility
Review before official use
  • Runs in your browser. Your file is processed on your own device and, on this site, is not uploaded to our servers.
  • Nothing is stored. Your file and its output are gone the moment you close or reload the page.
  • Review sensitive files (bank, ID, medical) and check the output before sharing it.

Every tool on FormatOS runs in your browser. Read our Privacy Policy and File Handling Policy.

Common uses

  • Catch indentation and quoting mistakes in a config
  • Confirm a YAML file has the structure you expect

Limitations

  • Anchors, aliases, tags and multi-document files are reported as unsupported

Where a YAML check fits

YAML fails in quiet ways: a tab instead of spaces, one key indented a space too far, a colon inside an unquoted value, the same key written twice. Many programs then read something different from what you meant, or refuse the file with an unhelpful message. This check parses the YAML and tells you exactly where it breaks.

It fits the moment before you commit a config change, paste a docker-compose or CI snippet into a ticket, or hand a data file to someone else. It is also useful for decoding an error from another tool: paste the file here to see the line and the reason in plain words.

It is a syntax check, not a schema check. It confirms that the YAML is well-formed and shows its top-level shape; whether the keys are the ones your application expects is a question for that application's documentation or schema.

What it checks

Paste the YAML, open a file or drop one on the input, and press Run. The whole document is parsed: nested mappings, lists, quoted strings with their escapes, comments, one-line [lists] and {maps}, and | or > multi-line text. A valid file gets a one-line summary, such as "Valid YAML: a mapping with 10 keys (version, services, …)", which confirms the top level is what you expected.

An invalid file gets the first problem found, with its line number: tabs in indentation, a line indented deeper than the key above it, a duplicate key, an unclosed quote, an unknown escape sequence, or a value that starts with a character YAML reserves, such as @ or `.

Everything runs in your browser. Nothing is uploaded, so it is fine for configuration that names internal hosts, though it is better not to paste real secrets anywhere.

What a pass does and does not mean

A pass means the file is well-formed YAML by the rules this checker applies. Some features are outside those rules and are reported rather than passed: anchors and aliases (& and *), tags (!), merge keys (<<), complex keys (?) and files with more than one --- document. If your file relies on them, the checker says so by line.

Values are read by the YAML 1.2 rules, where yes, no, on and off are text. Some older tools follow YAML 1.1 and read those as booleans; if your file will be read by such a tool, write true and false explicitly.

Only the first error is reported. Fix it and run again: a single indentation mistake often makes the lines below it look wrong too.

After it passes

Read the summary line. If it says a list where you expected a mapping, or fewer keys than you expected, the indentation is putting things somewhere you did not intend.

To see the full structure, run the same YAML through YAML to JSON: the JSON shows exactly which value belongs to which key.

For configuration that controls production systems, a pass here is a good first check, not a replacement for the application's own validation or a test deploy.

Frequently asked questions

That the YAML parses: consistent indentation with spaces, keys that appear once per mapping, closed quotes, valid escapes and well-formed lists and one-line collections. A valid file gets a summary of its top level, such as 'a mapping with 10 keys'.

It names the line and the problem, for example 'Line 7: tabs cannot be used for indentation in YAML; use spaces' or 'Line 12: duplicate key "port"'.

It parses the block YAML found in real config files, including nesting, lists and multi-line text. Anchors, aliases, tags and multi-document files are reported as unsupported rather than silently passed. It checks syntax, not a schema: it cannot tell you whether a key is one your application expects.

No. The conversion runs in your browser; your text or file is processed on your own device and, on this site, is not uploaded to a server, and we do not intentionally store it.

Related data tools

Tool last reviewed: September 27, 2026 · Report a problem