CSS Minifier
Minify CSS code for faster load times, without breaking strings and url() values, and keep full control of your stylesheets. GDPR-compliant.
Your inputs are processed in your browser and are not transmitted to our servers. Note: third-party resources (e.g. advertising and analytics from Google/Cloudflare) and an optional PayPal donation link may transfer data when loading or when clicked. Browser extensions or plugins may be able to read content that is visible in the input fields.
The result will appear here …
How to use this tool (video)
This video is hosted on YouTube. When you play it, data may be sent to Google.
CSS Minifier
The CSS minifier shrinks your CSS code for faster load times. It removes comments and excess whitespace but leaves strings and url() values untouched. The stylesheet stays functional while the file gets smaller.
What the minifier removes
- CSS comments
- Unnecessary spaces, line breaks and indentation
- Whitespace right next to brackets, colons, semicolons and commas
Content inside quotes and inside url() values is protected so wording, paths and calc() calculations stay intact. The tool shows the size saving in characters and percent.
Frequently asked questions
What does the CSS minifier remove?
The minifier removes CSS comments as well as unnecessary spaces, line breaks and indentation. Whitespace right next to brackets, colons, semicolons and commas is also removed.
Can the minifier damage my stylesheet?
No. Content inside quotes and inside url() values stays protected. Wording, paths and calc() calculations remain intact and the stylesheet keeps working.
Why are url() values protected?
Inside url() spaces or brackets can be part of the path. The minifier therefore leaves these values untouched so that no images or backgrounds break.
How much can I save?
The tool shows you the size saving in characters and in percent. The saving depends on your source code and is especially high for heavily commented or indented CSS.
Is my CSS code uploaded anywhere?
No. Minification runs entirely in your browser. Your CSS code is not transmitted to our server or stored.
How does the minifier differ from the formatter?
The minifier shrinks the file while the formatter makes code readable. The two processes are opposite: minifying removes whitespace, formatting adds clean structure again.