15,432 developers used QuickKit today — 100% free, runs entirely in your browser

HTML minifier — compress HTML markup online

Compress HTML documents by removing comments, collapsing whitespace between tags, and trimming optional syntax

JSONCSSHTMLJavaScript
HTML minifier
Input
Loading editor…
Minified output
Loading editor…

Ctrl+Enter to minify

HTML-specific

Why minify your HTML?

HTML documents delivered from a server or CDN should be as compact as possible. Uncompressed HTML has indentation, developer comments, and whitespace between tags that contribute nothing to the rendered page but add bytes to every network request. QuickKit's HTML minifier removes HTML comments, collapses whitespace between elements, and trims optional whitespace inside tag attributes. The result is markup that browsers parse identically to the original but transfers significantly faster — especially important for mobile users on slower connections and for improving Time To First Byte metrics.

Questions

Frequently asked questions

No — whitespace between block elements is not rendered. Whitespace inside inline elements and <pre> blocks is always preserved.
Inline <script> and <style> blocks have their whitespace collapsed but are not fully minified — use the JS and CSS minifiers for deeper compression.
Keep exploring

Related tools

All tools