Built and fact-checked by the DocNectar team — see our editorial standards
Key Features
Instant Calculation
Get accurate results in real time with our optimized algorithm.
Mobile Friendly
Fully responsive design. Works on all devices & screen sizes.
Privacy Focused
Your data stays on your device. We don't store any inputs.
100% Free
No hidden costs. This tool is completely free forever.
XML that isn't well-formed — a missing closing tag, an unescaped ampersand, mismatched nesting — will fail to parse in almost any consumer. This tool checks well-formedness using the same libxml engine behind PHP's DOM and SimpleXML, reporting the exact line and column of the first problem found.
How it works
Paste XML and the tool attempts to parse it, collecting any libxml parser errors. If none are found, the document is well-formed; otherwise the first error's line, column, and message are reported.
- Enter xML.
- Click Calculate to see your results.
Examples
A mismatched closing tag
<root><a>1</a><b>2</a></root> fails because the second element opens as <b> but closes as </a> — the parser reports the exact line and column where the mismatch was detected.
Who should use it
- Debugging a broken XML feed, config file, or API response.
- Quick sanity-check before feeding XML into another system.
Industry applications
- Web and API development
- Data integration and ETL pipelines
Advantages
- Reports the precise line and column of the first parser error.
- Uses the same libxml engine PHP itself relies on for XML parsing.
Limitations
- Only checks well-formedness, not conformance to any particular schema or DTD.
Common mistakes to avoid
- Leaving a raw & character in text content instead of escaping it as &.
- Assuming the reported error line is exactly where the mistake was made — sometimes the true cause (like an unclosed tag) is earlier, and the parser only detects the mismatch further down.
Best practices
- Fix the first reported error and re-check — later errors are sometimes just knock-on effects of the first one.
- For structural (not just syntax) validation against a defined schema, follow up with the XML Schema Validator tool.
Tips
- Pair this with the XPath Evaluator to query specific values once you've confirmed the XML is well-formed.