XML Formatter & Validator
Paste XML, then format it with proper indentation or check whether it's well-formed.
"Well-formed" vs "valid"
This tool checks that your XML is well-formed — every tag properly opened and closed, correctly nested — which is what a browser's XML parser requires. It doesn't check against a schema (DTD or XSD), so well-formed XML can still fail a stricter validation elsewhere.
About the XML Formatter & Validator
XML Formatter pretty-prints XML with indentation and checks that it is well-formed. Use it to read messy XML from APIs, feeds and configuration files.
Well-formed XML follows the syntax rules: one root element, properly nested and closed tags, quoted attributes and escaped special characters. "Valid" XML additionally matches a schema or DTD, which this tool does not check. The browser's XML parser reports errors, which helps you find the problem.
How to use it
- Paste your XML.
- Press Format or Validate only.
- Read the output or error.
- Press Copy output.
Tips and good to know
- Check for unclosed tags and unescaped ampersands.
- Keep a copy before editing.
- Use the XML to JSON tool to convert.
Frequently asked questions
Does it validate against a schema?
No.
Does formatting change data?
It adds whitespace between elements.
Is it private?
Yes.