How to Co-Author Macro-Enabled Excel Files in Microsoft Teams
Question details
The user needs to confirm whether a macro-enabled Excel workbook (.xlsm) can be co-authored in Microsoft Teams and how to handle VBA macros during collaboration.

- Product
- Microsoft Teams and Microsoft Excel
- Device & OS
- not provided
- Scenario
- A team needs to collaborate on an Excel workload tracker that contains VBA macros, using Microsoft Teams while sometimes opening the workbook in the Excel desktop app.
- Observed behavior
- You want to co-author the workbook in Teams without losing access to VBA macros, but you are unsure whether Teams and Excel for the web support macros and which storage location is required.
Confirm that the macro-enabled workbook is stored in OneDrive for Business or SharePoint Online, and make sure every co-author uses an Excel version that supports co-authoring and has the desktop app available for running VBA macros.
Store the macro-enabled workbook in OneDrive for Business or SharePoint Online
Use this when you need a supported location for Teams co-authoring and want to avoid file-locking issues.
Excel co-authoring in Teams relies on the file being hosted in OneDrive for Business or a SharePoint Online document library. Teams files are already saved to SharePoint or OneDrive, but the link used for collaboration must point to the hosted file, not a local copy.
In Microsoft Teams, select your team channel, click the Files tab, and then choose Open in SharePoint to access the underlying document library.
In SharePoint Online or OneDrive for Business, upload the macro-enabled workbook or verify that the existing workbook is stored in the document library rather than attached as a local copy.
Click the file and select Open in Desktop App. In the Excel desktop app, choose File > Share to invite co-authors with edit permissions.
Keep the workbook open in Excel desktop when you need to run or edit VBA macros. Excel for the web can open .xlsm files but cannot run VBA macros.
Open macro-enabled workbooks in Excel for the web and run VBA macros in the desktop app
Use this when you want to view or edit a macro-enabled workbook online but must execute VBA macros manually.
Collaborate on Excel Workbooks Without Microsoft 365 Restrictions
WPS Office is a free, lightweight Office alternative that opens Excel workbooks including macro-enabled .xlsm files, preserves familiar spreadsheet workflows, and offers WPS Cloud for sharing and collaboration without requiring Microsoft 365 or Teams.

Frequently Asked Questions
Can Excel for the web run VBA macros in a macro-enabled workbook?
No. Excel for the web can open a macro-enabled .xlsm workbook, but it cannot run or edit VBA macros. Open the workbook in the Excel desktop app and use the Developer tab to run macros.
Why can't we co-author a macro-enabled Excel file in Teams?
The file must be stored in OneDrive for Business or SharePoint Online, and all users must use an Excel version that supports co-authoring. If someone opens a local copy or the file is locked, co-authoring is blocked.
Do macro-enabled workbooks have to be stored in SharePoint Online or OneDrive for Business?
For co-authoring in Teams, yes. Teams uses SharePoint Online or OneDrive for Business as the file host. Local copies or unsupported locations prevent real-time collaboration.
Can WPS Office open a macro-enabled Excel workbook?
WPS Office Spreadsheets can open Excel workbooks including .xlsm files and works with common Excel formats. For full VBA macro execution, use Microsoft Excel desktop because macro support can vary in WPS Office.
How do I switch from Excel for the web to the desktop app to run macros?
Open the workbook in Excel for the web from Teams, then select Editing > Open in Desktop App or use the file menu to open it in the Excel desktop app. Use the Developer tab to run VBA macros.




