YAML Validator
Validate YAML syntax and view the parsed result.
Overview
YAML Validator checks YAML syntax live as you type and, when the document is
valid, shows the parsed structure as pretty-printed JSON. It uses js-yaml,
the same parser found in countless Node.js toolchains, so errors and type
inference match what your build pipeline will do. Useful for debugging CI
configs (GitHub Actions, GitLab CI), Kubernetes manifests, and Docker Compose
files before committing them.
How to use
- Paste or type your document into the YAML field.
- Read the status line below it:
Valid YAMLon success, or the parser’s error message — including the line and column of the problem — on failure. - When valid, review the Parsed (as JSON) panel to confirm the structure and inferred types.
Examples
Input:
server:
host: localhost
port: 8080
Parsed (as JSON): { "server": { "host": "localhost", "port": 8080 } } — note port is a number, not a string.
A tab character used for indentation produces an error naming the offending line, since YAML forbids tabs in indentation.
Notes
The validator parses a single document; multi-document streams separated by
--- are not fully reported. Validation covers syntax only — it cannot know
whether the keys are correct for the tool consuming the file (that requires a
schema-aware linter for the specific format).
Documents whose anchors and aliases reference each other in a way that
multiplies out are refused before parsing. A few hundred bytes of nested
aliases can expand to hundreds of megabytes — 253 bytes reaching 22.8 MB is
easy to construct — which would freeze the tab. Ordinary anchor use, including
the <<: merge keys that appear throughout Docker Compose and CI configs, is
unaffected. Input above 2 MB is also refused.