HTML, CSS and JavaScript minifier processes pasted code or a text file inside a browser worker.
Terser handles JavaScript, CSSO handles CSS, HTML Minifier Terser handles HTML and Prettier formats all three. No preview executes the submitted code; large or stalled jobs can be cancelled.
How to use
- Choose the language and minify or beautify operation.
- Paste or upload up to 2 MB; for JavaScript choose module mode and optional local-name mangling.
- Run the parser, review the output and byte counts, then copy or download it.
Frequently asked questions
Does beautifying restore original names?
No. Formatting restores layout, not original variable names, comments or source structure removed by compression.
Does this run my JavaScript?
No. The text is parsed and transformed in a worker. It is not evaluated or inserted into an executable document.
Are embedded HTML scripts compressed?
Not by this HTML mode. It preserves script and style bodies; select JavaScript or CSS separately to compress those languages.
Why did output grow?
Formatting adds readable whitespace. Even minification can add necessary syntax; the reported saving can be negative instead of hiding growth.
Choose JavaScript mode deliberately
ES module mode permits different top-level optimizations. Match the code’s actual execution context, and test the output in your application before replacing a production asset.
Whitespace can carry meaning
HTML uses conservative whitespace collapse and preserves preformatted content. CSS restructuring is disabled, while JavaScript licence/preserve comments are retained. Parser errors are reported rather than disguised as a successful result.
