Readable indentation should not quietly rename namespaces, reorder attributes, convert CDATA, remove comments, or rewrite an entity spelling. XMLClear keeps those constructs as source tokens after syntax succeeds.

Prefixes are spelling, namespace URIs are identity

Two documents may use different prefixes for the same namespace URI, and a default namespace changes the namespace of unprefixed element names within its scope. A formatter does not need to invent or normalize prefixes. XMLClear preserves every qualified name and xmlns attribute exactly in the source order and reports only how many namespace declarations the parsed tree contains. That count does not prove that the vocabulary is expected or that an application will bind it to the intended code.

Keep non-element nodes visible

Comments can carry operational notes, processing instructions can tell a consumer about an associated stylesheet or tool, and CDATA can make literal markup characters easier to author. XMLClear preserves their complete source spellings and shows separate counts. It never executes an instruction, renders SVG, applies XSLT, opens a referenced stylesheet, or inserts parsed nodes into the active page. Preservation means only that the text remains in the derived document, not that its effect is safe or understood.

A practical review before use

Keep the original document beside the derived result and compare the part you intend to use. Confirm that element and attribute names, namespace prefixes and declarations, entity spellings, comments, processing instructions, CDATA boundaries, and mixed text read as expected. If the receiving system treats whitespace-only text as data, prefer Check or keep the original source rather than assuming a formatter can infer a missing content model. Finally run the result through the same schema, tests, signature checks, and application workflow that normally accepts this XML. XMLClear deliberately cannot prove those separate contracts.