About CSS Minifier
Minify CSS to cut a stylesheet down to what the browser needs, so pages download a little faster. It's handy when a site has no build step: a WordPress child theme, a static landing page, or a style block you paste into a CMS. Paste the CSS or open a file, and the minified version appears as you type, with the size before and after and the percentage saved. The same site's scripts can be shrunk with the JavaScript Minifier.
Comments and whitespace are removed, and the last semicolon in each rule is dropped. Colors like #ffffff become #fff, and 0px becomes 0. License comments that start with /*! are kept, so copyright notices survive. Strings and url() values aren't touched, so file paths and quoted text stay intact. Keep your readable file for editing; if you lose it, the CSS Formatter spreads minified CSS out again. Nothing is uploaded, because it all runs in your browser.
How to use CSS Minifier
- 1Paste your CSS
Paste the stylesheet or open a CSS file.
- 2Check the savings
The CSS minifier updates as you type and shows the size before and after and the percentage saved.
- 3Copy or download
Copy the minified CSS or download it as a file.
Why use Cubfile for this
- Comments and whitespace out
Everything the browser ignores is removed, except /*! license comments.
- Shorter values
#ffffff becomes #fff, 0px becomes 0, and the last semicolon in each rule goes.
- Strings left alone
Quoted text and url() paths are never rewritten.
- Size before and after
See both sizes and the percentage saved before you copy.