Code Tower · room 29

HTML Minifier

Minify HTML including inline CSS and JS.

🔒 Processed in your browser · No upload · No sign-up

Minify HTML online

Reduce the size of HTML pages and email templates by collapsing whitespace, removing comments and minifying inline <style> and <script> blocks. Powered by html-minifier-terser, running locally in your browser.

Is "Remove optional tags & quotes" safe?

The HTML spec allows omitting some closing tags (like </li>) and attribute quotes, and browsers render the result identically. Some email clients and XML-based tools are stricter, so leave this off for email templates or XHTML.

Why is whitespace inside <pre> kept?

Whitespace is meaningful in <pre> and <textarea>, so it is always preserved. Between inline elements a single space is kept so words don't run together.