About this tool
Format CSS stylesheets with consistent indentation. Useful when reviewing API responses, cleaning config before commit, or sharing readable snippets in docs and PRs.
Paste minified CSS into Input. Click Format to expand rules with line breaks after braces and declarations. Example — Expand a minified rule set: try `main{margin:0;padding:1rem}.card{border:1px solid #ccc}` and expect something like `main { margin: 0; padding: 1rem; } .card { border: 1px solid #ccc; }`.
At-rules, nested CSS, and complex selectors may need a PostCSS/Prettier pass for production style. See also: CSS Minifier, and HTML Beautifier. Runs in your browser — nothing you paste gets uploaded.
How to use
- Paste minified CSS into Input.
- Click Format to expand rules with line breaks after braces and declarations.
- Copy the Output for readable reviews or docs.
- Pair with the CSS Minifier when you need the reverse direction.
Example
Expand a minified rule set
Input
main{margin:0;padding:1rem}.card{border:1px solid #ccc}Output
main {
margin: 0;
padding: 1rem;
}
.card {
border: 1px solid #ccc;
}Limitations
- At-rules, nested CSS, and complex selectors may need a PostCSS/Prettier pass for production style.
- Formatting does not lint or autofix vendor-prefix / compatibility issues.
- Comments can shift position when the input was heavily minified.
Related tools
2Frequently asked questions
What does the CSS Formatter do?
Format CSS stylesheets with consistent indentation. Runs in your browser — no install, no account.
How do I use the CSS Formatter?
Paste minified CSS into Input. Click Format to expand rules with line breaks after braces and declarations. Copy the Output for readable reviews or docs. Pair with the CSS Minifier when you need the reverse direction.
Is the CSS Formatter free?
Yes. No signup, no usage limits, no paywall.
Does the CSS Formatter upload my data?
No. Processing happens locally in JavaScript. Your input is not uploaded, stored, or logged.
What are the limitations of the CSS Formatter?
At-rules, nested CSS, and complex selectors may need a PostCSS/Prettier pass for production style. Formatting does not lint or autofix vendor-prefix / compatibility issues. Comments can shift position when the input was heavily minified.