YAML Formatter
Beautify and prettify YAML instantly — no upload, fully private. 100% free.
Built for Obsidian, Hugo, Jekyll, and CI pipelines.
How to use
- Paste your YAML (however messy) into the input box.
- The formatted YAML appears on the right.
- Copy or download the cleaned result.
Re-indents your YAML with consistent 2-space indentation and readable structure.
Example
name: demo
config: {debug: true, level: 3}
items: [a, b, c]name: demo
config:
debug: true
level: 3
items:
- a
- b
- cWhen this works best
Formatting only re-indents and re-flows; it does not change values. Anchors and merge keys are expanded, and comments are dropped during the re-dump.
How it differs from related tools
The YAML Minifier shrinks YAML into compact flow style; the Formatter keeps block style but only re-indents for readability.
Frequently asked questions
Is the YAML formatter free?
Yes, it runs in your browser and is free with no sign-up.
Will formatting change my data?
No. Formatting only changes whitespace and structure, not values.
Does formatting change my values?
No. It only adjusts whitespace and indentation; the data stays identical.
Are my comments kept?
No — js-yaml re-dumps the parsed structure, so comments, anchors, and aliases are dropped.