.docm File Extension
.docm file is, how to open it safely, how Poly supports it, and when to convert it to DOCX or PDF. File extension details for .docm
Partial Support| File type | Microsoft Word macro-enabled document |
|---|---|
| MIME type | |
| Encoding | Binary ZIP-based Office Open XML package with XML parts and an optional binary VBA project |
| Operating systems | Windows, macOS, Linux, iOS, Android |
| Opens with | Microsoft Word, Word for the web, LibreOffice Writer |
| Poly support | Partial. Poly processes DOCM documents when their registered MIME type is supplied. |
| Indexed by Poly | Yes, after processing. Poly indexes document text, pages, and visual similarity, but not VBA code. |
| Preview in Poly | Yes. DOCM files have a connected document preview, and macros do not run. |
| Poly agent | Partial. The agent can read the document, but it cannot inspect or execute its VBA project. |
What kind of file is a .docm?
A .docm file is a Microsoft Word document that can store Visual Basic for Applications (VBA) macros. It uses the registered application/vnd.ms-word.document.macroenabled.12 MIME type. The ordinary DOCX format uses the same basic Office Open XML family but cannot store VBA macro code.12
DOCM is a ZIP-based package containing XML document parts, images, and other resources. When a macro is present, Word adds a binary vbaProject part.3 The common ZIP header 50 4B 03 04 is not enough to identify DOCM because DOCX, XLSX, EPUB, and many other formats share it. Reliable inspection also checks the package's content types and relationships.
.docm attachment as potentially executable. You can read or make simple edits without enabling macros. Enable them only when you understand and trust the code.4How do I open a .docm on my computer?
- On Windows or macOS, Microsoft Word is the best choice for editing both the document and its VBA project.
- In a web browser, Word for the web can view and edit DOCM content, but its macros do not work.5
- On iPhone, iPad, and Android, Word opens DOCM files read-only and preserves macros without allowing them to run or be edited.6
- On Linux, LibreOffice Writer can open the document, but complex formatting and VBA behavior may not transfer perfectly.7
Do not enable content merely because the sender or filename looks familiar. A .docm suffix signals that the package is allowed to carry macros, not that every file contains them or that any embedded code is safe.
Poly support for .docm
Poly can preview a correctly identified DOCM document, index its readable text and rendered pages, and make that content available to the Poly agent. The connected preview requires a network connection. Macros do not run, and VBA source is not indexed or exposed to the agent.
Poly currently needs the registered MIME type during ingestion to apply these document features reliably. A file supplied only as a .docm filename may receive basic storage and filename search instead.
History of .docm
Microsoft introduced Office Open XML formats with Office 2007. Separating .docm from .docx made macro capability visible in the filename, unlike the older .doc convention. The specific DOCM media type was registered with IANA in February 2011, and IANA lists Microsoft Office as its application family.18
Working with .docm and alternatives
Choose the destination according to what must survive:
| Format | Best for | VBA macros |
|---|---|---|
.docm | An editable Word document that must retain automation | Preserved |
.docx | Ordinary editing and safer sharing when macros are unnecessary | Removed |
| Fixed-layout reading, review, or distribution | Not runnable |
Renaming .docm to .docx does not remove its macro project or convert the package. A proper conversion removes the vbaProject part, changes the internal document type, and then saves with the .docx extension.3 Keep the original until you have checked the converted document and any workflows that depended on its macros.
Footnotes
- Internet Assigned Numbers Authority. application/vnd.ms-word.document.macroEnabled.12 Media Type Registration. ↩ ↩2
- Microsoft. XML File Name Extension Reference for Office. ↩
- Microsoft. Convert a Word Processing Document from DOCM to DOCX. ↩ ↩2
- Microsoft Support. Enable or Disable Macros in Microsoft 365 Files. ↩
- Microsoft Support. Unable to View or Edit Office Files by Using Office Online or Office Web Apps. ↩
- Microsoft Support. Why Can't I Open My File in Word on a Mobile Device?. ↩
- LibreOffice Help. Using Microsoft Office and LibreOffice. ↩
- Microsoft Learn. Building Office Open XML Files. ↩