About JavaScript Formatter & Minifier
The JavaScript Formatter & Minifier beautifies messy JS with Prettier or minifies it for production. Configure indentation (2, 4 or 8 spaces), tabs or spaces, semicolons and single quotes, then copy or swap input and output. Everything runs locally in your browser, so your code stays private.
Features
- Beautify JavaScript via Prettier
- Minify JavaScript to reduce file size
- Configurable indent: 2, 4 or 8
- Tabs or spaces, semicolons and single quotes options
- Copy result or swap input and output
Frequently Asked Questions
Is my code uploaded anywhere?
No. Formatting and minification run entirely in your browser, so your code never leaves your device.
What does minify do?
Minify removes comments and unnecessary whitespace to reduce file size while keeping the code functionally identical.