Developer

HTML Formatter

Beautify and minify HTML markup.

This free HTML formatter cleans up messy markup with consistent, tag-aware indentation, or minifies it for production with a configurable indent size (2, 3 or 4 spaces, or tabs). Void elements such as br,img and input are handled correctly, and the contents of raw-text elements — pre, script,style and textarea — are preserved exactly so your code and whitespace-sensitive blocks are never mangled. Simple elements such as <li>one</li> stay on a single line for readable output.

Load markup by pasting, or upload a file in any of 30+ character encodings — UTF-8, UTF-16, every ISO-8859 and Windows code page, KOI8, Shift_JIS, GBK, Big5, EUC-KR and more — which is decoded to Unicode automatically. Then copy the result or download it as a file.

Related tools