About the Minifier

A free tool for shrinking HTML, CSS, and JavaScript, entirely in your browser.

What it is

The Minifier uses proper, well-maintained minification libraries for each language — Terser for JavaScript, csso for CSS, and html-minifier-terser for HTML — rather than naive text substitution. That means strings, template literals, and regular expressions are correctly understood and never corrupted, even when they contain characters that would confuse a simple find-and-replace approach.

Features

Auto-detect language

Paste any HTML, CSS, or JavaScript and it's identified automatically, or pick manually.

Size readout

See the original size, minified size, and percentage saved for every input.

Safe defaults

JavaScript variable mangling is off by default, kept readable-ish; a toggle turns it on for maximum compression.

Licence comments preserved

Comments starting with /*! survive minification across all three languages.

Copy and download

Copy the minified result or download it as a ready-to-use file.

Fully client-side

Your source code, even proprietary code, never leaves your browser.

Why minify

Minification strips out whitespace, comments, and other characters that browsers don't need to execute your code, shrinking file size without changing behaviour. Smaller HTML, CSS, and JavaScript files download and parse faster, which directly improves page load performance and Core Web Vitals.

Ready to use it?

Free, no sign-up required.

Open the Minifier