Skip to content
Toova
All Tools

HTML Minifier & Beautifier

Private by design — runs entirely in your browser

Minify or beautify HTML in your browser. Toova strips whitespace, comments, and optional quotes to shrink HTML for production, or pretty-prints minified markup into something you can actually read.

What HTML minification removes

Whitespace between tags, unnecessary quotes around attribute values, redundant closing tags, comments, and empty attributes all add up. Minify mode trims everything safely — the output renders identically in every modern browser. For very large pages or static HTML being served from a CDN, the savings on first-byte time are measurable, especially before compression kicks in.

Beautify mode

When you need to audit machine-generated HTML, debug a server-rendered page, or read the output of a static site generator, beautify mode is what you want. Toova takes flat single-line HTML and expands it into a properly indented tree with clear block boundaries. Indentation level is configurable — 2 spaces, 4 spaces, or tabs — depending on your reading preference.

Browser-only

All processing runs in your browser. The HTML you paste — even proprietary templates or sensitive markup — never leaves the page. That makes the tool safe for working with internal designs, customer-specific email templates, or anything covered by an NDA. The page works offline after first load.

Frequently Asked Questions

How much smaller is minified HTML?
Typically 5-15% smaller before gzip, more on pages with lots of whitespace and comments. After gzip the savings drop to a few percent — but every byte counts on the first paint of a page.
Will minification break my page?
No, as long as the input is valid HTML. The minifier preserves the DOM structure exactly. Whitespace between inline elements is sometimes meaningful, so the tool keeps it where it could affect rendering.
Does it strip comments?
By default, yes. You can preserve conditional comments (the old IE-only blocks) and license headers through the preserve-comments toggle. Regular comments are removed to save bytes.
Can I beautify a single line of HTML?
Yes. The beautifier parses any flat HTML and indents it according to the DOM tree. That makes it readable even when the input is minified output from a build pipeline.
Is my HTML sent anywhere?
No. Processing runs entirely in your browser. Nothing is uploaded or logged.