跳到内容
RapideTools

JavaScript 压缩器

保守地压缩 JavaScript。

Paste JavaScript to strip comments and collapse extra whitespace. This is a conservative minifier — it preserves strings, template literals and regex, and keeps newlines so automatic semicolon insertion still works. It does not rename variables. Everything runs locally in your browser.

保守压缩器:移除注释和多余空白;不重命名变量。如需完整压缩,请使用构建工具。

你的输入在浏览器本地处理 —— 不会上传、存储或记录。

为你节省时间了吗?请我喝杯咖啡

工作原理

  1. 1 Paste your JavaScript.
  2. 2 The minified output appears live.
  3. 3 Copy or download the .js file.

常见用例

  • Quickly shrink a small script.
  • Remove comments before sharing.
  • Reduce inline script size.
  • A fast, dependency-free first pass.

常见问题

Is my input sent to a server?

No. Everything runs locally in your browser — your input is never uploaded, stored or logged.

How thorough is the minification?

It is deliberately conservative: it removes comments and extra whitespace but does not rename variables or restructure code. For maximum compression, use a full bundler (esbuild, terser).

Could it break my code?

It preserves strings, template literals and regex literals and keeps line breaks to stay ASI-safe. Very unusual code could still differ — always test the output.

Is it really free?

Yes — free, with no signup and no limits.