<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:template match="*/@*" />
<xsl:template match="@*|node()">
<xsl:copy>
<xsl:apply-templates select="@*|node()" />
</xsl:copy>
</xsl:template>
</xsl:stylesheet>
XSLT Usage (Xml Transformation Policy)
XSLT Required to Remove All Attributes from XML File
You can remove all attributes in XML file using XSLT. You can clean all properties (attributes) of XML elements and preserve only content and structure.

