JavaScript Formatter & Minifier
JavaScript Workspace
Beautify, validate or minify JavaScript without executing the source code.
About
The XAVERT JavaScript Formatter & Minifier formats, validates and minifies JavaScript source code without executing it.
Main Features
- Beautify JavaScript with configurable indentation and brace style.
- Minify JavaScript with Terser compression and identifier mangling.
- Validate syntax before transformation.
- Switch between classic Script and ES Module parsing modes.
- Choose ES5, ES2015, ES2020 or ES2022 output targets.
- Use Safe, Balanced or Maximum minification presets.
- Control compression passes and comment preservation.
- Optionally preserve function and class names.
- Optionally optimize top-level identifiers.
- Optionally remove console calls and force ASCII-only output.
- Open .js or .mjs files with click or drag-and-drop.
- Compare input/output size, line counts and processing time.
- Copy, download or reuse the processed output as new input.
- Cancel long-running processing without freezing the page.
Privacy First
Your JavaScript source is processed in your browser and is not sent to XAVERT. The transformation libraries are fetched from public CDNs when needed, so an internet connection may be required before processing.
This tool targets JavaScript syntax supported by Terser and js-beautify. TypeScript and JSX require dedicated parsers and are not treated as standard JavaScript here. Minification can alter identifier names or remove code according to the options you explicitly enable.