Format, validate and minify XML with exact error lines. Keeps comments and CDATA. Runs entirely in your browser, so nothing is uploaded.
6 answers to what people ask most about the XML Formatter.
Paste it in. The status line shows Valid XML with the root element and element count, or the exact line, column and reason for the first error.
No. It checks that the XML is well-formed, meaning tags match, attributes are quoted and entities are defined. Schema validation needs the schema file and is not done here.
Elements that contain only text keep it exactly as written, and elements that mix text with child tags stay on one line, so spaces aren't added inside sentences.
Yes. CDATA sections, processing instructions and the DOCTYPE are kept as written. Comments are kept unless you turn off Keep comments.
Any element with xml:space="preserve" is printed exactly as it was, including its whitespace, in both Format and Minify modes.
Yes. It's free with no sign-up or limits, and it runs entirely in your browser, so what you type or paste never leaves your device. It works on phones and computers alike.
Something not working? Tell us and we'll fix it.
Report an issue