Format and beautify YAML files with proper indentation.
The YAML Formatter re-indents and normalizes YAML while keeping your comments, and reports syntax errors with their line and column, so it works as a validator too. Choose 2- or 4-space indentation. Everything runs in your browser, which matters when your YAML contains secrets.
Made for developers. Typical uses:
It normalizes layout but keeps your data unchanged, and it does not check YAML against a schema such as a Kubernetes or Docker Compose spec.
Accuracy: Output is tested against known inputs. For production code, review the result and run your own tests.
Why JSON that looks fine still fails to parse: trailing commas, single quotes, comments, NaN and oversized numbers, and how to validate, format and compare it fast.
Explore more in Developer Tools, read the guides and articles, or see how we test our tools.
Minify YAML configuration files by removing whitespace.
Best for trimming comments and blank lines from a CI/CD pipeline config before deployment
Format, beautify, and validate JSON data with proper indentation.
Best for formatting minified JSON from APIs for readability
Format and beautify XML data with proper indentation.
Best for making a minified API response readable before debugging it
Generate Docker Compose files for multi-container applications.
Best for scaffolding a docker-compose.yml for an app plus a database container without memorizing YAML syntax
Format and beautify SQL queries with proper indentation.
Best for formatting complex SQL queries for readability