XML Formatter / Beautifier
Beautify, validate, and minify XML with configurable indentation and self-closing tag control.
About this tool
The XML Formatter reformats minified or inconsistently indented XML into clean, readable output, while validating structure at the same time. Paste an XML document — a SOAP response, an RSS feed, an Android layout, a Maven pom.xml, or an exported config — and get back properly indented XML with a clear Valid/Invalid status badge.
Validation uses fast-xml-parser's strict XML validator, which reports the exact error type, line, and column when something is malformed — unclosed tags, mismatched nesting, or invalid characters. You don't have to guess where a document broke; the error points you directly at the problem.
Formatting options include indent width (2 spaces, 4 spaces, or tab) and a toggle for self-closing empty elements — choose between <empty/> and <empty></empty> depending on your downstream tooling's expectations. A separate Minify button strips all whitespace between tags to produce the smallest valid representation, useful when embedding XML into a payload or config value.
Everything runs client-side using fast-xml-parser compiled for the browser. No XML content — which may include internal API contracts, credentials in config files, or business data — ever leaves your tab.
