HTML Formatter
Beautify and indent messy HTML markup.
Input
Output
About the HTML Formatter
Format and indent HTML with a custom tokenizer that understands void elements, comments, and preformatted tags like pre, textarea, script, and style. Choose your indent size or minify to a single compact line.
Examples
Messy HTML
<div><p>hi</p></div>Output
<div>
<p>hi</p>
</div>Keyboard shortcuts
- Copy the main outputCtrl / ⌘ + Shift + C
- Download the resultCtrl / ⌘ + S
- Share this toolCtrl / ⌘ + Shift + S
- Reset the inputsAlt + R
- Open the tool search paletteCtrl / ⌘ + K
Related tools
CSS Formatter
HTML & CSS
Beautify or minify CSS with safe string handling.
Border Radius Generator
HTML & CSS
Fine-tune per-corner border radii visually.
Box Shadow Generator
HTML & CSS
Layer multiple box-shadows with a live preview.
Clip Path Generator
HTML & CSS
Design polygon clip-path shapes with a live preview.
CSS Animation Generator
HTML & CSS
Build keyframe animations visually with a live preview.
CSS Aspect Ratio Calculator
HTML & CSS
Simplify ratios and compute matching dimensions.
Frequently asked questions
Read more
- Web accessibility quick wins for developers
High-impact, low-effort accessibility fixes — semantic HTML, focus states, color contrast and ARIA done right — that don't require a redesign.
Version 1.0.0 · Updated 2026-08-06 · Runs entirely in your browser