freemium.tools
developer

XML Formatter

Indent, minify and validate XML, sitemaps and RSS feeds in your browser.

Runs entirely in your browser — nothing is uploaded.

Your result appears here.

About the XML Formatter

The Freemium.Tools XML formatter indents, tidies and validates XML in your browser, and can also squash a document back into one line — with no upload.

XML that arrives from an API, a sitemap or an export is usually one enormous line, which makes it impossible to see where an element starts and ends. Indenting it restores the tree so you can read and debug the structure.

The document is also checked as you type: if a tag is unclosed or an attribute is malformed, you are told immediately rather than after a failed import.

How to use it

  1. 1Paste your XML. Drop in a sitemap, an RSS feed, a config file or an API response.
  2. 2Tidy or squash. Indent with two spaces, four spaces or tabs, or minify it into a single line.
  3. 3Copy or download. Take the result to your clipboard or save it as an .xml file.

Frequently asked questions

Does it check whether my XML is valid?

It checks that the document is well-formed — every tag closed and properly nested. It does not validate against a schema or DTD, which is a separate step.

Is my XML uploaded?

No. Formatting and validation both run inside your browser tab, so confidential configuration files are safe to paste here.

Will it break CDATA or comments?

No. Comments, processing instructions and CDATA blocks are preserved as they are; only whitespace between elements changes.

Why would I minify XML?

Minified XML is smaller over the wire, which matters for sitemaps, SOAP payloads and anything stored in a size-limited field.

Can I use it for sitemaps and RSS?

Yes. Sitemaps, RSS and Atom feeds are ordinary XML, so they format and validate the same way.

Related tools