Skip to content

CSS minifier

Lighten your style sheets by removing whitespace, comments and unneeded characters.

Savings: {{ savingsPercentage }}% ({{ formatBytes(originalSize - minifiedSize) }} saved)
Source code (raw CSS) {{ formatBytes(originalSize) }}
Minified code {{ formatBytes(minifiedSize) }}

What is CSS minification?

The CSS minification is the process of removing from a stylesheet's source code (.css) every character that is not strictly needed for the web browser to run it.

What does this tool remove?

  • Comments: Blocks of text like /* commentaire */ that help developers but are ignored by browsers.
  • Spaces and line breaks: Line breaks, tabs (indentation) and the spaces around braces { } and colons :.
  • The last semicolon: The semicolon ; of the last rule in a block is not required in CSS, so it is removed to save a few bytes.

Impact on SEO (search engine optimization)

CSS is a render-blocking resource. This means the web browser pauses rendering the HTML page until it has finished downloading and reading the entire CSS file. By minifying your code, the file becomes much lighter (up to 30% savings). Your site displays faster, which directly improves your scores on Google PageSpeed Insights and helps your ranking in search engines.

More optimization tools:

How it works

How to use the CSS minifier

Lighten your style sheets by removing whitespace, comments and unneeded characters.

  1. Paste your content

    Paste your CSS code.

  2. Minify

    The code is compacted.

  3. Copy the result

    Copy or download the result in one click.

FreeNo subscription, no hidden limits.
No sign-upOpen the page and use the tool. That’s it.
InstantResults in seconds, on mobile too.
PrivateEverything runs in your browser.

About the CSS minifier

Minified CSS loads faster and improves the initial display of the page. Keep the source version for maintenance.

css minifier minify css online compress css css compressor reduce css size css optimizer minify stylesheet
FAQ

Frequently asked questions about the CSS minifier

Does minification break the styling?

No. The rendering stays identical.

What savings can I expect?

Often 15 to 40% less weight.

Should I minify during development?

No. Minify only for production.

Is the code sent anywhere?

No. Everything stays local.

Esc
↑ ↓ navigateEnter open