HTML · CSS · JS Formatter
Beautify or minify HTML, CSS, and JavaScript code in your browser.
Input
Output
About HTML · CSS · JS Formatter
Pretty-print compressed one-line code, or strip whitespace and comments to shrink files for production.
Beautify
Uses js-beautify to indent and line-break HTML/CSS/JS code per standard conventions.
Minify
JavaScript is safely compressed with Terser; HTML/CSS removes whitespace and comments. The savings ratio is shown.
Privacy
All processing is in the browser. Your code never leaves your device.
FAQ
Does minified code still work the same?
Terser preserves JavaScript semantics while shortening variable names. For large projects, prefer your build pipeline.
Does it support JSX or TypeScript?
Only standard ES2020 JavaScript, HTML, and CSS. JSX/TSX/TypeScript require a transpiler.