HTML Minifier

Strip comments, collapse whitespace and remove optional attribute quotes from HTML to cut its transfer size, typically by 10–20%. Paste the markup and copy the minified result. It runs in your browser, so an unreleased page's source stays on your machine.

Runs in your browser — nothing is uploaded

Questions

How much smaller will my HTML get?
Usually 10–20% before compression. The bigger win is gzip or brotli on the server, which typically takes 70% off — minifying first still helps, but it is the smaller of the two effects and should never replace compression.
Is minifying safe?
For ordinary markup, yes. Two things to watch: whitespace inside <pre> and <textarea> is significant and must be preserved, and inline JavaScript with no semicolons can break if lines are joined. Test the output before shipping.
Should I minify by hand?
No — do it in your build so the source stays readable. This tool is for a one-off, for an email template, or for checking how much there is to save before you wire up a build step.