How to use the CSS formatter
Paste a whole stylesheet or a single rule. The output updates as you type.
- Paste your CSS into the Input box, or press Paste. A minified production bundle or a few rules copied from dev tools both work, and Try it loads a short example.
- Set Mode to Beautify for one declaration per line, or to Minify to strip comments and whitespace.
- Choose the Indent: 2 spaces, 4 spaces or Tab. It only affects Beautify.
- Read the status line. It says "Beautified", or for Minify it shows the length before and after and the percentage saved.
- Press Copy or Download .txt, then rename the download to .css. Use as input moves the result back into the input box.
Beautify uses the js-beautify library in your browser. The stylesheet is never uploaded, which matters for unreleased designs and client work.