CSS Minifier

Conservatively compact CSS whitespace while retaining quoted values, comments, and token separators. Runs entirely in your browser.

Why Minify CSS? — Faster Rendering and Better Page Performance

This tool performs conservative CSS whitespace compaction, not full production optimization. It reduces repeated whitespace outside protected tokens without rewriting selectors or values.

What This Tool Preserves

CSS Minification Savings

Savings depend on repeated whitespace and may be small or zero. Comments and value syntax are deliberately retained. For stronger optimization, use a tested parser-based build tool and measure the compressed result.

CSS Performance Optimization Tips

Frequently Asked Questions

This conservative compactor protects strings, comments, URLs, and escapes and retains token separators. It is not a full CSS parser or validator; test your stylesheet in its target browsers before using the output.
Review and test the result first. This lightweight compactor is not equivalent to cssnano or a parser-based production pipeline, and deliberately skips more aggressive optimizations.
The tool does not rewrite at-rules or custom-property values. It compacts unprotected whitespace and retains comments. It does not validate CSS syntax or guarantee support for every extension.
Input processing is local to this tool. Shared page features may make network requests, and enabled browser drafts may retain text locally. Avoid pasting credentials or confidential material.
This tool compacts source whitespace; gzip/Brotli encodes bytes for transfer. They can be combined, but savings depend on the input and server settings and are not guaranteed.