HTML Formatter
Expand minified or messy HTML into readable, indented markup.
Why format HTML?
Templates exported from build tools, email builders and frameworks often arrive as a single giant line. Reading, diffing or patching that is painful. This tool re-indents the markup so nesting depth is visible at a glance — tags open and close on lines that line up visually, and it becomes obvious where a stray closing tag lives.
Inline text is handled carefully: a paragraph's text stays on the same line as its tag rather than being exploded one word per line, so the output stays copy-paste friendly.
Formatting is safe to run repeatedly — the output is idempotent, and no markup content is changed, only whitespace between tags.
FAQ
Will it break my JavaScript inside script tags?
Script and style contents are treated as raw text and kept as-is (not re-indented), so minified JS inside a script tag remains untouched.
Does it handle self-closing tags?
Yes. Void elements like br, img, input and meta are recognized and never receive an extra indent level.
Can it validate my HTML?
It reformats, it does not validate. For standards checking use the W3C validator — but re-indenting often makes missing closing tags visible immediately.