CSS minifier
Compress or beautify your CSS, with the byte savings.
- Instant
- Free
- Private (processed locally)
- No sign-up
Lighter CSS, or more readable — your choice
In production you want CSS that is compact to load fast; in development, CSS that is spacious to read. This tool goes both ways, and each time shows how many bytes you saved or added back.
-
Paste your CSS
One rule, a whole sheet, any size.
-
Minify or beautify
Maximum compression, or clean re-indentation.
-
Read the savings
Bytes before → after and percentage saved.
What minification removes
| Before | After |
|---|---|
| /* comment */ | (removed) |
| .box { color: red; } | .box{color:red} |
| margin: 0 auto ; | margin:0 auto |
| Line breaks and tabs | (removed) |
A deliberately simple, safe minifier: it renames nothing and doesn’t merge rules. For critical production, a build tool (cssnano, Lightning CSS) will go further.
Frequently asked questions
Why minify your CSS?
A lighter CSS file downloads faster: the page renders sooner and uses less bandwidth. On large files, removing comments, whitespace and line breaks often saves 20–40% of the size.
Does minification change the rendering?
No: it only touches invisible characters (spaces, breaks, comments) and the redundant final semicolon. Rules, values and selectors stay identical. The browser interprets exactly the same style.
What does “beautify” mode do?
The reverse: it re-indents compressed or messy CSS, one rule per line, with indentation, to make it readable and editable. Handy for deciphering a site’s minified CSS and understanding how it’s built.
Are my stylesheets sent online?
No: all processing happens in your browser, nothing is transmitted. You can minify confidential or proprietary CSS without it leaving your machine.