🔧 Utility

CSS Minifier Online Free

Minify and compress CSS code instantly in your browser. Remove comments, whitespace, and optimise values. Shows exact bytes saved. No upload required.

Minification Options
🎨 Original CSS
⚡ Minified Output

About CSS Minifier

CSS minification reduces your stylesheet file size by removing all unnecessary characters without changing how the styles work. Smaller CSS files load faster, reducing page load time and improving your Core Web Vitals score.

Optimisations applied: Remove comments (/* ... */), collapse whitespace and newlines, remove trailing semicolons inside rule blocks, shorten hex colours (#ffffff → #fff), remove unnecessary zeros (0px → 0, 0.5 → .5), and remove spaces around colons and braces.

Updated: May 2025 · Works on Chrome, Firefox, Safari, Edge · Mobile friendly

Frequently Asked Questions

Will minified CSS still work the same?+
Yes — minification only removes characters that have no effect on styling (whitespace, comments, redundant semicolons). The resulting CSS produces identical rendering in all browsers.
How much size reduction can I expect?+
Typically 20-40% for developer-written CSS. CSS with extensive comments can see 40-60% reduction. Combined with gzip on your server, total transfer reduction is typically 60-80%.
What does "Shorten colors" do?+
Six-character hex colours where pairs repeat can be shortened: #ffffff → #fff, #aabbcc → #abc. This is completely safe and saves several bytes per colour value across a stylesheet.
Should I minify CSS in development?+
No — keep original CSS during development for readability. Only minify for production deployment. Always keep your original source files — you cannot easily un-minify CSS.
Done!