What this XML tool does
It checks matching tags and root structure, formats valid XML with selectable indentation, and removes optional inter-tag whitespace for compact output. Processing stays in the browser.
How to use it
- Paste XML or load the example.
- Choose two spaces, four spaces or tabs.
- Format, minify or validate the document.
- Review the reported mismatch or unclosed-tag message if validation fails.
- Copy or download valid output.
Practical example
<?xml version="1.0"?>
<catalog>
<item id="1">ToolNovaX</item>
</catalog>Well-formedness versus schema validation
Well-formed XML has one root element, correctly nested matching tags and valid basic tag syntax. It can still violate an application’s expected data model. That second task requires a schema validator, which is not included here.
Common XML errors
- Mismatched opening and closing tag names
- Unclosed comments or CDATA sections
- Text outside the root element
- Multiple root elements
- Relying on external entities or remote DTDs
Methodology and limitations
A lightweight internal scanner reads quoted tag boundaries, declarations, comments and CDATA without executing XML. DOCTYPE is rejected before formatting. Namespace semantics, entity declarations, XSD validation and remote resources are outside this tool’s scope.