← All Tools

CSS Beautify Formatter🔒 100% local

Format and prettify CSS. Privacy-first, no server uploads, no tracking.

Related Tools

Border Radius PreviewBox Shadow GeneratorCode Heatmap

Reformats minified or badly indented CSS: each selector on its own line with an opening brace, two spaces of indent per nesting level, one declaration per line, a single space after the colon, comments on their own line, and runs of blank lines collapsed to one. Strings and comments are tracked while scanning, so a semicolon or brace inside either one does not split a rule. Your stylesheet is reformatted in the page and never leaves it.

How to use it

  1. Paste the CSS - minified is fine - and press Process.
  2. The first line reports how many rule blocks were seen; the formatted stylesheet follows.
  3. Check any declaration that came back without a trailing semicolon; the formatter adds one.
  4. Copy Output takes the whole formatted stylesheet, Clear empties both boxes.

Worked example

.btn{color:red}becomesBeautified 1 rule. .btn { color: red; }

The default example in the box.

@media (max-width:600px){.a{color:red}}becomesBeautified 2 rules. @media (max-width:600px) { .a { color: red; } }

The count is 2 because every opening brace is counted, and the at-rule counts as one of them.

When to use it

What it does not do