DEVELOPER TOOL · PRIVATE
CSS Minifier Online
Compress CSS by removing comments and extra whitespace.
Create a smaller CSS representation for simple stylesheets and snippets. Paste the input, make the change, then read the result before you copy it elsewhere.
Production CSS should usually be minified by a build pipeline.
Ready — input is processed locally.
This utility runs on the current device for the supported workflow. Kaazo does not need the pasted input to calculate the result.
What CSS Minifier does — and what it doesn’t
Create a smaller CSS representation for simple stylesheets and snippets.
Minification should change size, not meaning
Removing whitespace and comments is useful only while the output still parses the same way. Strings, regular expressions and significant whitespace are exactly where simplistic minifiers can go wrong.
Minification should not change how CSS resolves URLs or strings; if a stylesheet depends on unusual hacks, test the minified copy before deployment.
Where CSS Minifier stops
Use a production build tool when you need advanced JavaScript/CSS optimisation, bundling, source maps or compatibility transforms.
Example and result checks
Consider a stylesheet containing a .button selector, a color declaration and a background-image URL. A smaller version should still produce exactly the same appearance in the browser. Save an unminified reference copy and compare the page before and after changing the stylesheet, particularly when it contains font URLs, quoted strings or custom properties.
Minification is not the same as removing unused CSS. It cannot determine which classes your application adds at runtime, and a rule that looks redundant may be used only when a menu opens. For a production site, inspect both desktop and mobile states rather than relying on the final character count.
FAQ
What does CSS Minifier actually do?
Create a smaller CSS representation for simple stylesheets and snippets.
What can change the CSS Minifier result?
Removing whitespace and comments is useful only while the output still parses the same way. Strings, regular expressions and significant whitespace are exactly where simplistic minifiers can go wrong. Minification should not change how CSS resolves URLs or strings; if a stylesheet depends on unusual hacks, test the minified copy before deployment.
Does formatted or converted output prove the data is valid for my application?
No. CSS Minifier can perform the syntax or data operation described here, but your application can still impose its own schema, business rules, encoding or security requirements.
Related tools
After CSS Minifier, validate the output before feeding it into another transform. The data-format guide has broader context if you need it.