Developer tool
JavaScript Minifier
Apply conservative whitespace and comment removal to simple JavaScript.
Runs in your browserResult — 39% smaller
Conservative browser minification is best for simple scripts. Use a parser-based build minifier for production applications.
How to use this javascript minifier
- Paste the source text or code, then choose the conversion or formatting mode.
- Review the minified output and file-size difference. Check syntax, escaping, and edge cases against the source before using the result in a live project.
- Check the output against the source, then copy or download the finished result.
About this javascript minifier
The JavaScript Minifier lets you apply conservative whitespace and comment removal to simple JavaScript. The controls cover only the inputs needed for the result.
You can also use it to check source text for structural or syntax problems.
Example
Paste a readable source file into the JavaScript Minifier, compare the before and after byte counts, then test the minified output in its normal environment.
Common uses
- → apply conservative whitespace and comment removal to simple JavaScript
- → check source text for structural or syntax problems
- → prepare a clean version for testing or reuse