XML Beautifier & Minifier

Re-indent hard-to-read XML or strip it down to a single compact line. The document is parsed first, so the output is always well-formed.

Formatted XML will appear here.

Shortcuts: Ctrl/Cmd + Enter run · Ctrl/Cmd + Shift + F format

How to use

  1. 1Paste your XML into the left editor.
  2. 2Pick your indentation: 2 spaces, 4 spaces or tab.
  3. 3Click Beautify XML or Minify XML.
  4. 4Copy the highlighted output or download it as a .xml file.

Frequently asked questions