Skip to content

HTML / CSS / JS Minifier

Minify HTML, CSS or JavaScript by stripping comments and whitespace, with size savings shown.

About HTML / CSS / JS Minifier

Quickly minify HTML, CSS and JavaScript to reduce file size. The tool removes comments (while preserving string literals) and collapses insignificant whitespace, then shows how many bytes you saved. Everything runs locally in your browser.

How to use HTML / CSS / JS Minifier

  1. 1

    Choose CSS, JS or HTML.

  2. 2

    Paste your code into the input panel.

  3. 3

    The minified result appears instantly with the percentage saved.

  4. 4

    Copy the minified output.

Frequently Asked Questions

Is the minification safe?

It's conservative — comments are removed while respecting strings, and whitespace is collapsed without merging tokens. For maximum JS compression, use a full build tool like esbuild or Terser.

Is my code uploaded?

No. Minification is performed entirely in your browser.