How to use XML Validator
Check whether a local XML document can be parsed. The report identifies broken syntax and shows the root element when it succeeds.
- Paste the document or open the file, then validate.
- Read the parser message around any reported line or tag before changing the source.
- Select Validate and review the result.
Example input
<?xml version="1.0"?> <inventory><item id="104">Notebook</item><item id="105">Pencil</item></inventory>
Example use
Check an exported feed after editing an item description that includes an ampersand.
Output and compatibility
This is a well-formedness check. A parsable document can still violate a schema, contain unexpected element values or be rejected by a receiving application.
Troubleshooting
Start at the first reported issue and check unmatched tags, improperly escaped characters and missing namespace declarations.
Use XPath Tester to see whether a required element can be selected.
Frequently asked questions
Does it validate XSD?
The browser checks whether the XML is well formed. Schema checks require a separate validator.
Can I see the hierarchy after it parses?
Use XML Formatter to add indentation.