HTML Beautifier

Free

by DirtyMarkup

Provided by DirtyMarkup

Not yet rated
Platform
Web / API
Pricing
Free
Account required
No
Ads
Light
Last verified
17 hours ago
Developer
DirtyMarkup
Official URL

Overview

DirtyMarkup is a web-based code formatter that takes messy HTML, CSS or JavaScript and returns it neatly indented. You paste code into the editor, pick a few options and press the clean button. It has been around since 2009 and is aimed at web developers who inherit minified, machine-generated or badly indented markup and want something readable.

The tool no longer lives on its own domain. The old dirtymarkup.com address now forwards to a section of the 10 Best Design website, where the formatter is presented as one of that company's design tools. HTML, CSS and JavaScript each have their own tab.

The settings cover indentation (tabs or 2, 3, 4 or 8 spaces), a preferred line length, whether the HTML output should be a full page or just a fragment, brace placement for scripts and a handful of switches such as adding blank lines for clarity, allowing proprietary attributes and cleaning up HTML exported from Microsoft Word. The page also advertises a REST API for cleaning code from your own programs.

Screenshots

Features

  • Formats HTML, CSS and JavaScript on separate tabs
  • Indent with tabs or 2, 3, 4 or 8 spaces
  • Preferred line length from 80 to 200 characters, or none
  • HTML output as a full page or a code fragment
  • Option to tidy HTML exported from Microsoft Word
  • Four brace styles for JavaScript
  • CSS options for new lines between rules and selectors
  • REST API for cleaning code programmatically

Privacy

See the official privacy policy. The tool page says nothing about how pasted code is handled, and it loads Google AdSense and Google Analytics scripts.

Pros & Cons

Pros

  • No account needed: paste code and clean it
  • One page handles the three main front-end languages
  • More formatting switches than most paste-and-format pages
  • An API is offered for automated use

Cons

  • The page carries Google ad slots and links promoting its host's agency rankings
  • The options are not explained on the page
  • No privacy statement on the tool page about what happens to pasted code
  • The original dirtymarkup.com address has a certificate problem before it forwards

Community Reviews (0)

No written reviews yet — be the first to rate this tool.

Similar Tools