Beautify / minify XML with syntax highlighting
XML (Extensible Markup Language) is a markup language widely used in SOAP services, Office documents, SVG graphics, and enterprise system configurations. An XML formatter converts compressed or messy XML into a properly indented hierarchical structure for easy reading and editing.
| Feature | XML | JSON |
|---|---|---|
| Comments | <!-- --> |
Not supported |
| Attributes | <tag attr="v"> |
Not supported |
| Schema | XSD / DTD | JSON Schema |
| Use cases | SOAP, Office docs, SVG | REST APIs, config files |
Core rules: Must have a single root element; tag names are case-sensitive; special characters must be escaped (& < >); attribute values must be quoted.
web.xml, pom.xml, Spring configs, and other enterprise configuration files<?xml ...?>) are supportedNo. The tool preserves all namespace declarations and prefixes. Formatting only affects indentation and line breaks — no semantic content is modified.
Yes. <![CDATA[...]]> blocks and <?...?> processing instructions are correctly preserved and formatted.
The tool will report an error indicating the position of the unclosed tag. XML strictly requires all tags to be properly closed (self-closing tags must be written as <br />).