Dev
XML Formatter
Formatted XML replaces the current editor value.
Editor
Frequently Asked Questions
What is XML formatting?
XML formatting (pretty-printing) adds consistent indentation and line breaks to make XML documents readable. It does not change the document's structure, element values, or attributes — only the whitespace between tags.
Does formatting affect XML whitespace-sensitive documents?
Yes. In some XML documents (like SVG or certain data formats), whitespace inside text nodes is significant. Adding newlines and indentation to text nodes can change the document's meaning. Use formatting tools cautiously on whitespace-sensitive XML.
What is the difference between XML and HTML?
XML is a markup language for structured data — tags are custom and self-describing. HTML is a specific XML-like language for web content with predefined tags. XML requires strict well-formedness (closed tags, proper nesting); HTML browsers are more forgiving of malformed markup.