HTML Formatter
Format HTML and Vue templates, including embedded CSS and JavaScript, without changing how text renders.
About this tool
Format HTML or Vue templates with Prettier, the formatter most web projects use, including any CSS in <style> and JavaScript in <script>. Choose indentation, line width, one attribute per line and where closing brackets go.
By default, whitespace is only added where it can’t change how text renders between inline elements like <a> and <strong>, so formatting never introduces visible gaps. Choose “Keep exactly” to change no whitespace at all.
Your markup is parsed and printed as text. It’s never rendered, so scripts in it never run and nothing it references is loaded.