Skip to content
MixTool

CSS minifier

Compress stylesheets for production — whitespace, comments and redundant rules removed, with the savings shown before and after gzip.

  • Runs entirely in your browser
  • Free · no sign-up
  • Works on phone and desktop
Loading tool…

Lighter stylesheets, faster rendering

CSS blocks rendering, so every kilobyte you remove helps pages appear sooner. The minifier (powered by CSSO) strips comments and whitespace, shortens colors and zero values, and goes further than simple whitespace removal by merging duplicate selectors and restructuring rules when it's safe to do so.

Values that are easy to break — calc() expressions, custom properties, grid templates and vendor hacks — are handled correctly. The stats show the original, minified and gzipped sizes so you know what you gained.

How to minify CSS

  1. 1

    Paste your stylesheet

    Or open a .css file.

  2. 2

    Choose restructuring

    Leave it on for the smallest output.

  3. 3

    Copy or download

    Drop the minified CSS into your site.

Key features

  • Structural optimization

    Merges duplicate rules and shorthand properties.

  • Safe with modern CSS

    calc(), variables and grid values stay intact.

  • Gzip stats

    Real-world transfer savings.

  • No upload

    Processed in your browser.

Common uses

  • WordPress and theme tweaks: Minify a custom stylesheet before uploading.
  • Static sites: Ship production CSS without a bundler.
  • Performance audits: Fix “minify CSS” warnings in PageSpeed Insights.

Tips and good to know

  • Turn off restructuring if your CSS relies on the exact order of duplicate rules for overrides.
  • Need to read the minified file later? Expand it with the CSS Formatter.

Frequently asked questions

Is minified CSS still valid CSS?

Yes. Browsers read it exactly the same way; it just has no unnecessary characters.

What's the difference between minifying and gzip?

Minifying removes characters permanently. Gzip compresses the file during transfer and is undone by the browser. Use both for the best results.

Can minifying change how my site looks?

Standard minification can't. Rule restructuring is designed to be safe, but if something changes, switch it off and minify again.