Converter · SOTA YAML 1.2.2 · schema-safe
YAML Formatter & Validator
Format, validate, and normalize YAML with support for YAML 1.2.2 (2021), multi-document streams (---), anchors (&) and aliases (*), and block/flow style conversion.
How to Use YAML Formatter & Validator in 3 Steps
- Configure. Paste YAML into the input. The tool validates against YAML 1.2.2 and detects common mistakes (tabs, unescaped colons, ambiguous booleans).
- Process. Pick mode: Prettify (normalize indent 2 or 4 spaces), convert block to flow style, or validate-only with error line/column.
- Export. Copy the formatted output. Anchors (&), aliases (*), and tags (!!) are preserved. Multi-document streams (---) stay intact.
Why YAML Formatter & Validator on Pixlane
YAML formatting is needed for Kubernetes manifests, GitHub Actions workflows, CloudFormation templates, Docker Compose files, and anywhere human-edited config is shared. Pixlane parses YAML 1.2.2 (the latest spec from 2021), handles multi-document streams, and gives precise error messages with line and column for common mistakes like tab indentation or unquoted special strings.
- YAML 1.2.2 Compliant — The 2021 spec revision — fixes long-standing ambiguities around booleans (yes/no removed), null, and number parsing. Matches Kubernetes and GitHub Actions behavior.
- Multi-Document Streams — Supports YAML streams with multiple --- separators. Each document validated independently.
- Anchors & Aliases — Preserves &anchor definitions and *alias references — critical for CloudFormation templates and Ansible playbooks with shared configs.
- Precise Errors — Indent mismatches, unquoted special strings (on/off/yes/no), tab characters, and duplicate keys each produce actionable error messages with line and column.
Frequently Asked Questions
What's new in YAML 1.2.2?
The 2021 revision (erratum) clarifies that yes/no/on/off are NOT booleans (only true/false). Numbers with leading zero (0755) are strings, not octals. Cleans up historical ambiguities that made YAML unpredictable.
Does it handle Kubernetes manifests?
Yes. Kubernetes uses standard YAML 1.2. The tool correctly handles multi-document streams, anchor-based DRY configs, and complex nested structures typical of kustomize/helm output.
Is my YAML private?
Yes. All parsing happens in your browser. Your YAML — which may contain cluster configs, API tokens, or deployment secrets — never leaves your device.
Is this tool free?
Yes. YAML Formatter on Pixlane is completely free with no signup required.