XML formatter and validator
Check XML well-formedness with line numbers, and reformat with 2- or 4-space indentation or minify.
How to use
- Paste XML.
- Choose an indentation or minify.
- Format, then copy or download the result.
What it supports
Validates element nesting, attributes, entities, comments, CDATA, and the single-root rule — it does not validate against DTDs or schemas. Elements containing text are never re-indented, so meaning is preserved. Entity references are kept as written. Up to 200,000 characters.