Remove Foreign Namespaces
Remove namespaces (topic) · Remove namespaces (project)
Cleanup ⚡ tab → Styling group
Removes all non-MadCap namespace declarations, attributes and elements from your topics — the typical leftovers of Word imports, such as xmlns:o, xmlns:w, <o:p> elements and o:gfxdata attributes. Text content is always preserved.
What gets removed
- Foreign namespace declarations (
xmlns:o,xmlns:w,xmlns:v,xmlns:st1, ...) - Attributes in foreign namespaces (e.g.
o:gfxdata) - Elements in foreign namespaces (e.g.
<o:p>) — these are unbound, so their text content survives
MadCap namespaces, the standard XHTML namespace, and xml: attributes are always kept.
Remove namespaces in the current topic
- Open the topic.
- Click Remove namespaces (topic) in the Styling group.
- Confirm. The document is saved and backed up first.
- If nothing foreign is found, you are told so; otherwise the topic is cleaned, saved, and reloaded in the editor.
Remove namespaces in the whole project
- Click Remove namespaces (project).
- Confirm. The scope is the whole Content folder including sub-folders — topics and snippets.
- Only the affected files are backed up to a ZIP archive (in your configured backup folder) and checked out of source control before they are cleaned.
- A summary reports how many files were cleaned and where the backup ZIP is.
Notes
- Files that cannot be parsed as XML are skipped and listed in the summary — they are never half-cleaned.
- There is no dry-run mode; the ZIP backup is your undo. Restore it with Backup and Restore.
- Run Validate XML first if you suspect broken markup — namespace cleaning requires valid XML.
Was this page helpful?
Still stuck? Contact support