JavaScript formatter and minifier
Format JavaScript with consistent indentation or minify it by removing whitespace and comments, without running the code.
- Runs in your browser
- No upload
- Result stays on your device
Privacy & limitsRuns in your browser. Nothing is uploaded.
Input content stays in this tab; Refentra does not upload or store it. Optional aggregate action counts are sent only with your usage consent. Clear the workspace when finished.
Supported profile: JavaScript parsing only; no execution; minifier compression/mangling disabled. 100,000 units.
Maximum text: 200,000 UTF-16 units; parser limits can be smaller. Worker time limit: 15 seconds (regex 1.5 seconds).
Check the input and the result
- Prepare and choose the operation
Paste JavaScript source and choose compact or readable formatting. The tool parses the code without running it.
- Check a concrete example
Use this sample and compare the indicated result: const total = 1 + 2; → minify → const total=1+2;
- Check the output before you reuse it
Check the tokens and comments before you reuse the output. Accepted syntax doesn't prove that imports or runtime behavior are correct.
Answers for this task
Are variable names renamed or expressions evaluated?
No. Compression and mangling are turned off. The formatter is not an optimizer, an interpreter or an obfuscator.
What should I check if the input fails?
Fix the syntax error that is reported. TypeScript annotations and project-specific JSX need their own compiler and can't be handled by plain JavaScript formatting.
Where does this tool stop?
The output is not a security review, a dependency bundler or a runtime test. Keep any required license notices when you distribute code.