The semantics of this CSS have been kept the same, but the extraneous whitespace has been removed, the identifiers compressed, and unnecessary definitions purged from the stylesheet. This gives you a much smaller CSS for production use.

But don’t just take our word for it; why not try out css-size, a module especially created to measure CSS size before & after minification.

Original (gzip)

325 B

Minified (gzip)

177 B

Difference

148 B

Percent

54.46%

By default, cssnano performs safe optimisations on your CSS file, but we also offer an advanced preset with techniques that you can use to maximise compression. For more details, see our optimisations guide.

Technology

cssnano is powered by PostCSS, a tool for transforming styles with JavaScript. Specifically, its plugin architecture allows us to compose cssnano out of small modules with limited responsibilities. It also allows you to easily insert cssnano into your build step, along with other processors that can lint your CSS for errors, or transpile future syntax.