YAML Formatter & Validator
Validate YAML syntax, re-indent it consistently, and convert freely between YAML and JSON.
About this tool
YAML Formatter & Validator checks that your YAML is syntactically correct, re-indents it consistently, and converts freely between YAML and JSON. Paste a config, catch indentation mistakes, and get clean output in the format you need.
YAML powers Docker Compose files, Kubernetes manifests, GitHub Actions workflows and Spring Boot application.yml, where a single misplaced space can break a deployment. This tool helps you spot those errors early, and because it runs in your browser, sensitive configuration never leaves your machine.
How to use
- Paste your YAML into the input area.
- Format it to apply consistent, correct indentation.
- Watch for validation errors that flag invalid syntax.
- Switch to convert YAML into JSON, or paste JSON to get YAML back.
- Copy the cleaned-up result for your config file or pipeline.
Features
- Validate YAML and surface syntax errors.
- Re-indent YAML consistently for readability.
- Convert YAML to JSON and JSON to YAML.
- Great for Compose, Kubernetes, CI workflows and application.yml.
- Handles nested maps, lists and multi-line values.
- Runs client-side — your configuration is never uploaded.
Frequently asked questions
Does my YAML get sent to a server?
No. Validation, formatting and conversion all happen locally in your browser, so secrets and configuration in your YAML stay private.
Why is my YAML invalid when it looks fine?
YAML is indentation-sensitive, so the usual culprits are mixing tabs with spaces, inconsistent indent levels, or a missing space after a colon. The validator points you toward the problem area.
How does converting YAML to JSON work?
The YAML is parsed into a data structure and then serialized as JSON, so maps become objects and lists become arrays. You can convert back the same way for a JSON-to-YAML result.
Can it handle multi-document YAML files?
YAML files can separate documents with a --- marker to hold several documents. Convert or format one document at a time for the clearest results when a file contains more than one.