HTML Minifier

Make HTML smaller for faster pages. Whitespace is collapsed conservatively, so your layout won't change.

Runs in your browser · nothing uploadedFree · no sign-up
Loading tool…

How to use the HTML Minifier

  1. Paste your HTML.
  2. Choose whether to keep comments.
  3. Copy or download the minified result.

Features

  • Inline CSS and JS minified too
  • Conservative whitespace collapsing
  • Size savings shown

Frequently asked questions

Can minification break my page?

The settings are conservative, but test the result, especially pages that rely on whitespace between inline elements.