Utilzivo

CSS Minifier

Make your stylesheets smaller and faster to download. This CSS minifier strips comments, removes unnecessary whitespace, and tightens up syntax — turning readable CSS into a compact file browsers can fetch quicker. You get a clear before/after size comparison with the percentage saved, plus copy and download options. All processing happens in your browser; nothing is uploaded.

How to Use the CSS Minifier

  1. Paste your stylesheet into the input box.
  2. Click Minify CSS. Comments disappear, whitespace collapses, and redundant characters like the last semicolon in a rule are removed.
  3. Check the stats line for the exact byte savings.
  4. Copy the result or download it as a .css file and use it on your site.

Practical example

Your theme’s custom stylesheet is 22 KB with generous comments and indentation. After minifying, it is 14 KB. You link the minified file in your HTML head instead of the original, and every visitor downloads 8 KB less on each page view — a small change that adds up across thousands of visits and nudges your page-speed scores upward. If you edit styles often, keep the readable source in your project folder and re-minify after each change; the whole round trip takes seconds, so there is no reason to ever ship the bulky version to visitors.

Key features and benefits

  • Comment stripping: all /* ... */ comments are removed safely.
  • Syntax tightening: spaces around braces, colons, semicolons, and commas are removed, and trailing semicolons before } are dropped.
  • String protection: quoted strings (like content: "a b") are shielded during minification, so intentional spacing inside them survives.
  • Media-query safe: required spaces (for example after @media) are preserved so the CSS stays valid.
  • Instant stats: see original size, minified size, and percentage saved on every run.
  • Zero setup: no build tools, no packages, no configuration — paste, minify, and done.

Limitations

This minifier does not rewrite your CSS: it will not merge duplicate rules, shorten color codes like #ffffff to #fff, or remove unused selectors. Very unusual CSS (such as strings containing comment-like text) is handled conservatively but you should still test the minified stylesheet in a browser. Keep your readable source file for future edits and deploy only the minified copy.