Code Beautifier
FeaturedDeveloper ToolsBeautify minified code in JS, TypeScript, HTML, CSS, JSON, and XML.
What is Code Beautifier?
Code Beautifier restores proper indentation, line breaks, and spacing to minified or compressed code across JavaScript, TypeScript, HTML, CSS, JSON, and XML. It is the reverse of minification — useful for reading third-party or legacy code.
How to use Code Beautifier
Select the language
Choose JavaScript, TypeScript, HTML, CSS, JSON, or XML using the language tabs.
Paste minified code
Paste any minified, one-line, or poorly formatted code into the input area.
Set indent size
Choose 2 or 4 spaces for indentation depth.
Read the output
The right panel shows your code with proper indentation and syntax highlighting that adapts to dark or light editor mode.
Copy or download
Click Copy or Download to use the beautified code in your editor or version control system.
Who uses Code Beautifier?
Vendor code inspection
Security engineers
Un-minify third-party JavaScript libraries or browser extensions to audit their source code for malicious behaviour.
Legacy codebase reading
Developers
Beautify old, compressed PHP, JS, or CSS files from a legacy system before refactoring or documenting them.
Learning from production sites
Students & junior developers
Format a site's production CSS or JS to understand how production-quality code is structured.
Related Tools
HTML/CSS/JS Minifier
Minify HTML, CSS, and JavaScript to reduce file size for production.
JSON Formatter
Format, validate, and beautify JSON with syntax highlighting.
SQL Formatter
Beautify SQL queries with dialect support and customizable indentation.
Regex Tester
Test and debug regular expressions with real-time match highlighting.
FAQ
What languages does the beautifier support?+
Can it unminify/deobfuscate code?+
Does it handle JSX/TSX?+
More Tools
View all