CSS Beautifier

Paste CSS and get readable, consistently indented rules back. Minified files, one-line sheets and mixed indentation are all handled in your browser, so the stylesheet never leaves your device.

Free, no sign-up. Your code stays in your browser.

Your CSS

Up to 300,000 characters.

Paste CSS and press Format.

How to

Beautify CSS in three steps

  1. Paste your stylesheet

    Drop in a whole file or a few rules. Minified CSS from a build tool works as well as hand-written CSS.

  2. Choose the layout

    Pick spaces or tabs, whether each selector in a list goes on its own line, and whether rules are separated by a blank line.

  3. Format, copy or download

    Press Format, then copy the result or save it as a .css file.

Good to know

  • Beautifying only changes spacing. Selectors, values and comments are left as they are.
  • Source maps are not rebuilt. If you are debugging a minified file, use the original source or a browser’s source map instead of formatting the output.
  • To go the other way, use the CSS Minifier.
  • The limit is 300,000 characters. Split a very large stylesheet into parts.

FAQ

CSS beautifier questions

Is my CSS uploaded anywhere?

No. The formatting runs in your browser and the page makes no network request with your code.

Does it change what my CSS does?

It changes only whitespace and line breaks. Rules, selectors, values and comments stay the same, so the page should look the same. If a rule contains unusual syntax, compare before and after.

Does it work with SCSS, Sass or Less?

It is made for plain CSS. Simple SCSS and Less often format acceptably, but features such as mixins and nested maps may not come out the way you want, so check the result.

Can it restore my original formatting from a minified file?

No. Minifying removes comments and some spacing, and that information cannot be recovered. The beautifier gives you a consistent readable layout, not the original one.

Is there a size limit?

Yes: 300,000 characters. Longer input gets a message and is not formatted; split it into parts.