CSS Formatter
Beautify minified or messy CSS into readable code, or minify a stylesheet for production. Nesting, @media rules and comments are handled.
How to use CSS Formatter
- Paste CSS into the Input panel, or open a .css file.
- Choose Format or Minify as the mode.
- For formatting, pick the indent you want.
- Copy the output or Download it as a file.
Frequently asked questions
How do I beautify minified CSS?
Paste the minified CSS and choose Format. Each rule and declaration is put on its own line with consistent indentation.
Does minifying CSS remove licence comments?
Ordinary comments are removed, but comments that start with /*! are kept, which is the usual convention for licence notices.
Does it support CSS nesting and media queries?
Yes. Nested rules, @media and other at-rules are formatted and minified correctly.
What if my CSS has a missing brace?
The tool warns you to check your braces so you can find the unbalanced rule before using the output.