Will XML attribute reordering or whitespace show up as a diff?
Yes, both will. A text diff compares characters line by line, so reformatting, attribute reordering, or whitespace inside elements all show up as differences even when the document is logically identical. Click Format on both panes first to even out indentation; attributes stay in the order they were written, so a reorder still shows. For element trees with deeply nested children, a structural compare via XSLT or Canonical XML is the next step up. For reviewing a pom.xml, a manifest or a Spring context, Format plus a text diff is usually enough.
Does the order of attributes on an element matter?
No, not to an XML parser. The XML 1.0 spec says attribute order is not significant, so <img src="a.png" alt="x"/> and <img alt="x" src="a.png"/> represent the same element. A character diff will still flag the reorder because it sees the raw text. Format here keeps attributes in their written order, so it will not hide the swap. Run both files through Canonical XML first (xmllint --c14n sorts attributes) and compare the output.
How do XML namespaces affect the diff?
Namespaces are URI-based, but you bind them to short prefixes in the document. Two files that bind http://maven.apache.org/POM/4.0.0 to different prefixes are equivalent under the Namespaces in XML spec, but the text diff will mark every prefix swap as a change. The practical workaround is to format both files and use matching prefixes on both sides. For automated pipelines, a Canonical XML pass normalises this away.
Can I diff XML files with CDATA sections?
Yes. CDATA sections are just text content with the XML parser told not to interpret it, so <![CDATA[<b>raw</b>]]> compares as the literal characters inside. Long CDATA blocks (script tags, embedded HTML, SQL) diff cleanly. The one gotcha is that you cannot have ]]> inside a CDATA section; if your data contains that sequence, the source must split it across two CDATA blocks, which the diff will show as written.
Should I use XSLT instead of a diff?
Use XSLT when you want to transform XML or normalise it before comparing (sort children, drop comments, canonicalise namespaces). Use this diff when you want to see what changed between two specific files. The two are complementary: an XSLT pre-pass plus this diff is a strong workflow for noisy machine-generated XML. For most code-review use cases (pom.xml, AndroidManifest, application context), the diff alone is enough.
Does the encoding declaration or BOM affect comparison?
A bit. The <?xml version="1.0" encoding="UTF-8"?> line is itself part of the document text, so swapping UTF-8 for UTF-16 shows as a one-line diff. A UTF-8 byte order mark (BOM) at the very start is a single hidden character. Upload drops it, because the browser's file reader strips a leading BOM, but text pasted from some editors still carries one. If two pasted files look identical and the diff flags the very start of line 1, suspect the BOM.
Why do my SOAP envelopes diff weirdly when I rename a namespace prefix?
Because text diff is namespace-blind. Renaming xmlns:soap to xmlns:s and updating every <soap:Body> to <s:Body> is a no-op to an XML parser; the bound URI is unchanged and the document is logically identical. The character diff sees every tag as different and lights up the page. The fix is to canonicalise both sides before diffing. XML Canonicalization (C14N, RFC 3076) is the spec used by XML signatures specifically to handle this. Tools like xmllint --c14n or xmlstarlet c14n produce a canonical form that survives prefix renames.
Does the XML diff need an account?
No, and it is free. Format, Minify, validation, Upload and the diff itself all work without signing in, and there is no cap on how many XML files you compare. Ads on the page cover the hosting. Signing in only adds a dashboard of your share links, so you can delete one before it expires.
How is this different from other online XML diff tools?
A few things. The parse, format, and diff all run in your browser, so your XML only leaves the tab if you click Share. Plenty of online tools POST it to a server first. The highlighting lands on tag names, attributes, and text rather than whole lines. Validation uses the native DOMParser your browser ships, and Format only adds line breaks and indentation between tags, so a well-formed pom.xml stays well-formed after formatting.
Can it compare two XML files by uploading them?
Yes, each pane has its own Upload button. It takes .xml, .pom, .config and .svg files, so load the old file on the left and the new one on the right. The file is read locally and never sent anywhere. You can also paste from the clipboard if you only have the text, which is handy for a SOAP body or RSS snippet pulled from a log.
Can I diff three XML revisions together?
No, the page holds exactly two documents. With three revisions of a config or a feed, run two passes, first against second and then second against third, and each diff shows one round of edits. For a folder of XML files you would script xmllint or a build-time diff instead; this tool is for the focused two-file review.
Is it safe to paste sensitive XML like config files?
Yes, unless you share it. While you compare, your XML stays on your machine: no upload, no logging of what you paste, and no analytics on the content, so a web.config with a connection string or a SOAP envelope with a token stays in the tab. Share is the exception, because it stores both panes on our servers for the link. That said, treat any real secret with care; the safest habit is to redact passwords and keys before pasting, here or anywhere.