CSS Minifier

Compress and minify CSS instantly by removing comments and whitespace — with size savings shown.

Loading tool…

Minify your CSS in one click

The CSS Minifier compresses your stylesheet by stripping comments, collapsing whitespace, and removing unnecessary characters — without changing how it works. Paste your CSS and instantly get a smaller version, along with the exact size savings. It runs entirely in your browser, so even large stylesheets are minified instantly and privately.

What is CSS minification?

Minification removes everything a browser does not need to apply your styles: comments, line breaks, indentation, and the spaces around braces, colons, and semicolons. The result is functionally identical CSS that is significantly smaller. Smaller files download faster, which improves page load time — a factor in both user experience and search ranking.

What the minifier removes

RemovedExample
Comments/* like this */
Line breaks & indentationMulti-line rules become one line
Spaces around symbolsa : b ;a:b
Redundant semicolonsThe last ; before }

How to use it

  1. Paste your CSS into the box.
  2. The minified version and the percentage saved appear instantly.
  3. Click Copy minified to grab the result.

Why minify CSS?

  • Faster page loads — fewer bytes to download, especially on mobile.
  • Better Core Web Vitals — smaller render-blocking CSS helps your scores.
  • Lower bandwidth — cheaper to serve at scale.
  • Cleaner production assets — ship compact files while keeping readable source.

Keep a readable source copy

Always minify a copy, not your working file. Develop in well-formatted, commented CSS so it stays maintainable, then minify as a final step before deploying. Most build tools do this automatically, but this tool is perfect for quick one-off compression, snippets, inline styles, or projects without a build pipeline.

Private and free

Your CSS is processed entirely in your browser — nothing is uploaded or stored. The tool is completely free with no limits on file size.

Frequently asked questions

Does minifying change how my CSS works?

No. Minification only removes comments and unnecessary whitespace. The resulting CSS behaves identically.

How much smaller will my CSS be?

It depends on formatting and comments, but 20–50% is common. The tool shows the exact savings.

Should I minify my source file?

No. Keep a readable, commented source and minify a copy for production.

Is my CSS uploaded?

No. Minification happens entirely in your browser. Nothing is uploaded or stored.