CSS Formatter & Minifier

Format CSS into readable, indented rules, or minify it for production.

Processed on your device. Files are not uploaded

How to format CSS

  1. Paste your CSS

    Paste or type your CSS into the box.

  2. Choose

    Format into readable rules, or Minify for production.

  3. Copy the result

    Copy the result, or use it straight away.

Worked example

This is what CSS Formatter & Minifier gives for its own sample values. Open the tool above and change anything to try your own.

CSS

.card{padding:12px;color:#0f766e}.card:hover{color:#134e4a}@media(max-width:600px){.card{padding:8px}}

Formatted

.card {
  padding:12px;
  color:#0f766e;
}
.card:hover {
  color:#134e4a;
}
@media(max-width:600px) {
  .card {
    padding:8px;
  }
}

About CSS Formatter & Minifier

Turn compressed CSS into readable, indented rules, or minify your stylesheet to reduce its size.

FAQs

Does it change how the page looks?

No. Only whitespace changes.

Can I format HTML too?

Use HTML Formatter & Minifier.

Related tools