Input
Output

About the XML formatter

Bytewrench's XML formatter beautifies and minifies XML and checks it for well-formedness — all in your browser. Paste messy, single-line or minified XML and it re-indents the document into a clean, readable tree; switch to minify to strip whitespace for transport. Malformed XML is reported with the parser's error message so you can fix it fast.

It works with any XML dialect — config files, SVG, RSS, SOAP, sitemaps and more — and never sends your data to a server.

Beautify & minify

Pretty-print with 2/4-space or tab indentation, or compact to a single line.

Well-formedness check

Validates the document and surfaces the exact parser error when it isn't valid.

📊
Document stats

See element count and input/output size as you format.

🔒
Private & offline

All parsing and formatting happen locally in your browser.

Frequently asked questions

Does this validate XML against a schema?

It checks well-formedness — correct nesting, closed tags and valid syntax — using the browser's XML parser. It does not validate against a DTD or XSD schema.

Will it format SVG, RSS or SOAP?

Yes. Any well-formed XML dialect, including SVG, RSS/Atom feeds, SOAP envelopes and sitemaps, formats correctly.

What does minify do?

Minify removes the whitespace between elements to produce the smallest valid XML, useful for reducing payload size in transport.

Is my XML uploaded anywhere?

No. Everything is processed in your browser and nothing is sent to a server.