HTML Formatter
Beautify messy or minified HTML with clean indentation, or minify it for production.
Loading tool…
How to use the HTML Formatter
- 1
Paste HTML or open an .html file.
- 2
Choose Beautify or Minify and set the indentation.
- 3
Copy the result or download it.
Frequently asked questions
Are <script> and <style> blocks formatted?
Yes. Inline JavaScript and CSS are indented along with the markup.
Is my HTML run or rendered?
No. It is treated as plain text and formatted in your browser; nothing is executed or uploaded.