quialo.

CSS Minifier

Paste CSS above to minify it.

Paste your CSS and get a compact, production ready version in one step. This minifier removes comments and unnecessary whitespace, tightens the spacing around braces, colons, semicolons, and combinators, and drops the redundant semicolon at the end of each block. String values and url() contents are preserved exactly, so nothing that depends on spacing breaks. Everything runs in your browser, so your styles never leave your machine.

How to use

  1. Paste or type your CSS into the input box on the left.
  2. The minified result appears live in the output box on the right.
  3. Check the status line to see the original size, the new size, and the percentage saved.
  4. Click Copy to put the minified CSS on your clipboard, or Reset to start over.

Examples

  • Input: .title { color: red; font-size: 16px; } produces .title{color:red;font-size:16px}
  • Input: a > b + c { margin : 0 ; } produces a>b+c{margin:0}
  • Input: .x { content: "hello world"; } produces .x{content:"hello world"} (the spaces inside the string are kept)

FAQs

Does this change how my CSS behaves?
No. The output is functionally identical. It only removes comments and whitespace that the browser ignores, and it drops the last semicolon in each block, which is optional in CSS.
Are string values and url() paths safe?
Yes. Anything inside single or double quotes is preserved exactly, and the contents of url() are kept as written, including spaces, so values that depend on whitespace are not corrupted.
Is my CSS uploaded anywhere?
No. The minifier runs entirely in your browser. Your CSS is never sent to a server.
What happens if my CSS has a syntax problem?
If a comment, string, or url() is left open, the tool stops and shows a clear message instead of producing broken output. Fix the unterminated part and it will minify.
Why is the trailing semicolon removed before each closing brace?
The semicolon after the last declaration in a block is optional in CSS, so removing it saves a few bytes without changing the result.

Related tools