📝 Text & List
XML Formatter
Format, indent and pretty-print XML. Validate well-formedness. Free.
XML Formatter
How to use the XML Formatter
1
XML well-formedness
Well-formed XML requires: one root element, all tags balanced and properly nested, case-sensitive matching of opening and closing tags, all attribute values in quotes, special characters escaped (&, <, >). This tool checks well-formedness and reports the first error if any.
2
XML vs HTML formatting
XML and HTML formatting look similar, but XML is strict. Every opening tag must have a matching closing tag (<br/> not <br>), and tags are case-sensitive (<Title> ≠ <title>). The browser's DOMParser handles both — this tool uses its "text/xml" mode for strict validation.