HTML Beautifier
Beautify HTML with Prettier: consistent indentation plus formatting of embedded CSS and JavaScript.
Runs in your browserHTML → HTML
Loading tool…
Example
<ul><li><a href="/">Home</a></li><li>About</li></ul>
<ul> <li><a href="/">Home</a></li> <li>About</li> </ul>
How to use the HTML Beautifier
- Paste or type your HTML into the input area, or open a file from your device.
- Adjust the options above the editor if the tool offers any.
- Review the HTML result, then copy it or download it as a file.
Privacy and limitations
- Your data is processed on your device and is not uploaded to any server.
Related converters
HTML ViewerPreview HTML safely in a sandboxed frame where scripts, forms and network requests are blocked.HTML to JSX ConverterConvert HTML to React JSX: class to className, inline styles to objects, self-closing void tags and JSX comments.HTML MinifierMinify HTML: remove comments and collapse whitespace while preserving <pre>, <textarea> and <script> contents.Markdown FormatterNormalise Markdown with Prettier: consistent list markers, headings, emphasis and table alignment.Less FormatterFormat Less stylesheets with Prettier, keeping variables, mixins and nested rules readable.GraphQL FormatterFormat GraphQL queries, mutations, fragments and schema definitions (SDL) with Prettier.SCSS FormatterFormat SCSS/Sass stylesheets with Prettier, handling nesting, variables, mixins and maps.Java FormatterFormat Java source code with Prettier and prettier-plugin-java: classes, records, lambdas, generics and long call chains.