CSS Formatter & Minifier

Minify or beautify CSS in your browser with comment, indentation, line-ending and color options, then copy or download the result.

Conservative CSS formatting preserves text, URLs, math and declaration order. Comment removal keeps empty markers to preserve token boundaries. Color conversion handles whole RGB/hex color declarations; sorting and unused-CSS removal are unavailable.

Input CSS

Output CSS

Processed CSS will appear here

Formatting Options

CSS Formatter & Minifier

Paste CSS and choose Minify or Beautify. Minification runs in a worker and applies the selected comment and level options; beautifying lets you choose indentation, line endings, color format and vendor-prefix organization. The result reports original and processed sizes, compression ratio, selectors and properties.


The formatter is conservative: it preserves text, URLs, math and declaration order. Sorting properties and removing unused CSS are not performed, and color conversion applies to whole RGB/hex color declarations. Review the output in your target stylesheet because a formatter does not validate browser behavior or project-specific syntax.

Features

  • Minify or beautify CSS in a separate browser worker.
  • Choose comments, basic/aggressive minification, indentation, line endings and color format.
  • Review sizes, compression ratio, selector/property counts and processing errors.
  • Copy or download the processed stylesheet; sorting and unused-CSS removal are unavailable.

How to use

  1. Paste the CSS into the input area and choose Minify or Beautify.
  2. Set the relevant comment, indentation, line-ending or color options.
  3. Review the processed output and the size/statistics panel.
  4. Copy or download the result, then verify it in the stylesheet and browser where it will run.