Toolbench

CSS Minifier

Strip comments and whitespace from CSS to cut file size.

Runs entirely in your browser. Nothing you enter is uploaded.

How to use

  1. Paste your CSS.
  2. Press Minify.
  3. Check the size saving.
  4. Copy or download the minified file.

Example

A stylesheet with comments and indentation often shrinks by 20 to 40 percent.

About this tool

The minifier removes comments, collapses whitespace, drops spaces around punctuation and removes the final semicolon before a closing brace. Quoted strings and url() values are never changed. It does not merge or rewrite rules, so the result behaves the same as the original.

Frequently asked questions

Is it safe for all CSS?

It keeps strings, url() content and calc() spacing intact. Always test the minified file on your site.

Does it rename classes or merge rules?

No. It only removes characters that do not affect how the CSS works.

Related tools