How to Unlock a Protected .xlsm (Macro-Enabled) Excel File
Updated March 2026 · 4 min read
The .xlsm format is Excel's macro-enabled workbook — it's identical to .xlsx except it can contain VBA macros. Because it shares the same ZIP+XML internal structure, all the same protections apply, and all the same removal techniques work.
What Is a .xlsm File?
When you save an Excel workbook that contains VBA macros, Excel forces the .xlsm extension instead of .xlsx. Internally, the file is still a ZIP archive containing XML worksheets, style definitions, and relationships — plus an additional vbaProject.bin file that holds the macro code.
Types of Protection in .xlsm Files
.xlsm files can have all the same protections as .xlsx, plus one extra:
- Sheet protection — prevents editing cells on individual worksheets
- Workbook structure protection — prevents adding/deleting/reordering sheets
- Write protection — requires a password to save changes
- Read-only recommendation — prompts users to open as read-only
- VBA project password — prevents viewing or editing the macro code (unique to .xlsm)
For a full comparison, see our guide on Excel password types.
Unlock your .xlsm file instantly
XL Unlocker removes all protections from .xlsm files — including VBA project passwords — for free.
Unlock Your .xlsm FileHow XL Unlocker Handles .xlsm Files
- Upload your .xlsm file (it stays in your browser — never uploaded to a server)
- The tool unzips the archive and scans all XML files for protection tags
- It removes
<sheetProtection>,<workbookProtection>, and other protection XML tags - If a
vbaProject.binis found, it invalidates the VBA password hash - The file is re-packaged and downloaded with all macros preserved
Will My Macros Still Work?
Yes. XL Unlocker only modifies protection metadata — your VBA code, formulas, data, and formatting remain completely untouched. The .xlsm extension is preserved in the output file.
What About the VBA Project Password?
After unlocking, Excel may show a brief warning about the VBA project key when you first open the file. Simply go to Developer → Visual Basic, then Tools → VBAProject Properties → Protection tab — the lock checkbox will now be unchecked, giving you full access to the macro code. For more details, see our VBA password removal guide.
Limitations
- File-open encryption (AES-256) cannot be removed from .xlsm files either
- .xlsb files (binary format) are not supported — see our main guide