Code Minifier & Beautifier
Minify or beautify JavaScript, CSS, HTML, JSON, XML and SQL.
Drop a file here
or choose a code file — it is processed in your browser
Conservative transforms: comments and whitespace are removed or re-indented, but nothing is renamed, tree-shaken, or restructured. Always test minified output before shipping it.
Input
Minified output
function greet(name){console.log('Hello, '+name)}About the Code Minifier & Beautifier
One tool for compacting or formatting code in JavaScript/TypeScript, CSS, HTML, JSON, XML/SVG and SQL. Comments and whitespace are stripped safely around strings and regular expressions, or the code is re-indented with your chosen indent size. Language is auto-detected from what you paste or drop, and byte-size savings are shown for every run.
Examples
Minify CSS
body {
color: red;
}Output
body{color:red}Beautify JSON
{"a":1,"b":[2,3]}Output
{
"a": 1,
"b": [2, 3]
}Keyboard shortcuts
- Copy the main outputCtrl / ⌘ + Shift + C
- Download the resultCtrl / ⌘ + S
- Share this toolCtrl / ⌘ + Shift + S
- Reset the inputsAlt + R
- Open the tool search paletteCtrl / ⌘ + K
Related tools
Android APK Analyzer & Explorer
Dev Utilities
Open an APK, decode its manifest and browse or download every file inside.
JavaScript / TypeScript Playground
Dev Utilities
Write and run JavaScript or TypeScript with a live console.
JavaScript Object to JSON
Dev Utilities
Convert a JS object literal into strict, valid JSON.
Package Manager Command Converter
Dev Utilities
Convert install/run/exec commands between npm, yarn, pnpm and bun.
Package.json Validator
Dev Utilities
Validate package.json fields, semver ranges, and scripts.
UUID Validator
Dev Utilities
Validate and inspect UUIDs, including version and timestamp.
Frequently asked questions
Version 2.0.0 · Updated 2026-08-21 · Runs entirely in your browser