Validators 100% Free

XML Validator

Check whether your XML is well-formed and get clear error messages for any problems.

Loading tool…

Validate your XML instantly

The XML Validator checks whether your XML is well-formed and reports a clear error if it isn't. Paste your XML and get an instant verdict — valid or invalid with the parser's message. It uses the browser's native XML parser, so the result matches how real applications will read your document. Everything runs locally, keeping your data private.

What is well-formed XML?

XML has strict structural rules, and a document that follows them is "well-formed." That means every tag is closed, tags are properly nested, there is a single root element, attribute values are quoted, and special characters are escaped. A document must be well-formed before any program can parse it, so this is the essential first check for any XML — config files, RSS feeds, SOAP messages, sitemaps, and data exports.

How to use it

  1. Paste your XML into the box.
  2. See instantly whether it's well-formed.
  3. If invalid, read the error message to locate the problem.

Common XML errors

ErrorExample
Unclosed tag<item> with no </item>
Mismatched nesting<a><b></a></b>
Multiple rootsTwo top-level elements
Unescaped &Raw & instead of &amp;
Unquoted attributes<a href=x>

Well-formed vs valid

There are two levels of XML correctness. Well-formed means the syntax is correct — the check this tool performs. Valid (in the formal sense) additionally means the document conforms to a schema or DTD that defines which elements and attributes are allowed. Most everyday problems are well-formedness errors, which is why catching them first saves the most time.

Tips

  • Make sure there's exactly one root element wrapping everything.
  • Escape &, <, and > inside text and attributes.
  • Match every opening tag with a closing tag, correctly nested.

Private and free

Validation happens entirely in your browser — your XML is never uploaded or stored. The tool is completely free with no limits.

Frequently asked questions

What does 'well-formed' mean?

It means the XML follows syntax rules: closed and properly nested tags, one root element, quoted attributes, and escaped special characters.

Does it validate against a schema?

No. It checks well-formedness (syntax). Validating against a DTD or XSD schema is a separate, stricter check.

Why is my XML invalid?

Common causes are unclosed or mismatched tags, multiple root elements, and unescaped & characters. The error message points to the issue.

Is my XML private?

Yes. Everything runs in your browser and nothing is uploaded.