About the XML Minifier
Pretty-printed XML is easy to read but larger to send and store. This minifier removes whitespace between tags and, if you want, comments — without touching text content or CDATA sections.
The saving is shown so you can see the difference. Use XML Formatter to make it readable again.
How to use the XML Minifier
- Paste XML.
- Choose whether to remove comments.
- Copy or download the minified XML.
Features
- Batch files: run the tool on up to 200 files with the same settings and download every result as one ZIP
- Removes inter-tag whitespace
- Optional comment removal
- Keeps CDATA and text
- Shows size saved
Supported formats
- Plain text
Frequently asked questions
Can minifying change the meaning of XML?
Whitespace between elements is normally insignificant. If your format treats it as data (mixed content), check the output.
Is my text sent anywhere?
No. Everything runs in your browser, so nothing you paste is uploaded or stored.