HTML Beautifier

Indent HTML so the nesting of tags is easy to follow.

HTML Beautifier

.html · .xhtml · .htm

Paste text or open a file to see the result.

What it does

Puts HTML tags on their own lines and indents them by depth. Handy when you copy the source of a page or get a template on a single line and need to find where an element starts and ends. You get the same markup, laid out so the nesting is clear.

About the .html format

.HTML file extension
File Type
Hypertext Markup Language File
Developer
W3C / WHATWG
Category
Web Files
MIME
text/html

HTML is a markup language that defines the structure and presentation of content on the World Wide Web. It is one of the core technologies, along with CSS and JavaScript, that helps render web pages in all their glory.

Also works with

HTML Beautifier questions

How do I use the HTML Beautifier?

Paste the text into the Input box or open a file, set the options, then copy or download the result.

Does renaming a file to .html change its format?

No. The extension only tells programs what to expect, and the content of the file stays the same. To change the format, convert the file. The .html page lists programs and converters for it.