JS Minifier
Minify JavaScript code to reduce file size
Original Size
Settings
What is JS Minifier?
JS Minifier compresses JavaScript code by removing whitespace, comments, and shortening variable names using the Terser engine. This reduces file size for faster page loads and lower bandwidth costs while preserving the code's functionality.
How to use
- Step 1 — Paste your JavaScript code into the input editor, or upload a .js file directly.
- Step 2 — Configure minification options: toggle mangling (variable name shortening), compression level, and whether to remove console.log statements.
- Step 3 — Click Minify to process the code. View the size reduction percentage and download the minified file, or copy the output to clipboard.
Result
You have a 45KB utility library with extensive comments and long variable names. Paste it in, enable mangling and compression, and get a 12KB output — a 73% reduction ready for production deployment.
Related Tools
Webpage to PDF
Capture a webpage as a PDF
Privacy Policy Generator
Generate a privacy policy for your site
Terms of Service Generator
Generate a terms of service document
Cookie Consent Generator
Generate cookie consent banner code
CSS Minifier
Minify CSS code to reduce file size
HTML Minifier
Minify HTML code to reduce file size