Free CSS Minifier
Paste any stylesheet and get a compressed version back — comments stripped, whitespace collapsed — with the exact byte savings shown.
Original
0 B
Minified
0 B
Saved
0%
Strings inside quotes (like content: "a b") are preserved exactly.
How to use the CSS minifier
- Paste your stylesheet into the box — any size, any formatting.
- Click Minify. Comments are removed, whitespace is collapsed, and redundant semicolons go away.
- Check the byte savings, then Copy the result or Download it as a .css file.
Why minify CSS
Every byte of CSS travels down the wire on every page load, and browsers do not care about your careful indentation. Minification removes everything humans need and machines do not: comments, line breaks, extra spaces, and the last semicolon in each rule block. On a typical hand-written stylesheet this cuts 20–40% of the file size, which means faster first paint — especially on mobile connections. This minifier is careful where naive ones are not: quoted strings (like content: "hello world") are left byte-for-byte intact, so decorative text never breaks. One habit worth keeping: always minify a copy. Keep your readable source file for editing, and deploy the minified version. If you ever need to debug production styles, browser dev tools can pretty-print minified CSS back into readable form in one click.
Frequently asked questions
Will minification break my CSS?
No. The minifier only removes comments, collapses whitespace, and drops redundant semicolons — all changes that are invisible to the browser. Quoted strings are preserved exactly.
How much smaller will my file get?
Typically 20–40% for hand-written CSS. Heavily commented or loosely formatted files shrink the most. The stats above show your exact savings.
Should I edit the minified file?
No — always keep your readable source file and re-minify after changes. Minified output is for deployment only.
Is my CSS uploaded anywhere?
No. Minification runs entirely in your browser. Your stylesheet never leaves your device.