JavaScript, CSS & HTML Minifier

Remove comments and unnecessary spaces and line breaks from JavaScript, CSS or HTML. Anything inside strings, template literals and regex literals is left alone so behavior doesn't change, and you see the before-and-after size.

Paste code

Result

 

Only comments and whitespace are removed. Names are left alone — renaming without scope knowledge silently breaks code, and it does not make the code unreadable anyway.

About this tool

How to use it

  1. 1 Paste the code to minify.
  2. 2 Leave the type on Auto or choose JavaScript, CSS or HTML, then press Minify.
  3. 3 Check the result and the size saved, then copy it.

Good to know

  • The page audit reads HTML you paste — use the Link checker to follow a link
  • YAML support covers the widely used syntax only
  • JWT decoding unpacks the contents; it does not verify the signature

Frequently asked questions

Does it shorten variable names?

No — only comments and whitespace are removed. For renaming, use the minify step of your build tool.

Does it obfuscate code?

No. Minified code is still perfectly readable.

Could minifying break my code?

Only things that can't change behavior are removed. // or /* inside strings, templates and regexes aren't treated as comments.

Esc