How to Open a Local Windows Folder from Excel for the Web
Question details
The user wants to open a local Windows folder directly from a cell, button, or Office Script while working in Excel for the Web.

- Product
- Excel for the Web
- Device & OS
- Windows
- Scenario
- Attempting to link or trigger File Explorer to open a local directory from an online spreadsheet.
- Observed behavior
- Excel for the Web cannot launch File Explorer or open local system directories, and Office Scripts do not support this action due to cloud and browser restrictions.
Understand that modern web browsers enforce strict security sandboxes, meaning online applications like Excel for the Web cannot directly interact with your local file system or launch File Explorer.
Use Desktop Excel with VBA Macros
Switching to the desktop version of Excel bypasses browser restrictions, allowing you to use VBA to directly open a local Windows folder.
Since Excel for the Web and Office Scripts run in a secure cloud environment, they cannot execute local computer commands. By opening the file in the desktop app, you regain access to VBA (Visual Basic for Applications), which can interact with Windows File Explorer.
While your file is open in Excel for the Web, click the 'Viewing' or 'Editing' button on the ribbon, and select 'Open in Desktop App'.
In desktop Excel, press 'Alt + F11' to open the VBA Editor.
Insert a new module and write a simple shell script, such as: Shell "explorer.exe C:\Downloads", vbNormalFocus
Return to your worksheet, insert a shape or button, right-click it, select 'Assign Macro', and choose the script you just created.

Trigger a Local Folder via Power Automate
Bridge the web-to-desktop gap by using Power Automate to trigger a local desktop flow from an online action.
Switch to WPS Office for Seamless Local File Management
Avoid the strict limitations of web-based spreadsheet tools. WPS Office is a free, lightweight, and powerful desktop suite that natively supports local file hyperlinks, macros, and offline file management while maintaining high compatibility with Microsoft Office formats.
- 1. Download WPS Office: Install the free WPS Office desktop suite on your Windows PC.
- 2. Open Your Spreadsheet: Launch WPS Spreadsheet and open your existing Excel file.
- 3. Create a Local Hyperlink: Right-click any cell, select 'Hyperlink', and easily link directly to your local Windows folders without web browser restrictions.

Frequently Asked Questions
Can I use a standard hyperlink to open a local folder in Excel for the Web?
No, Excel for the Web blocks standard 'file:///' protocol hyperlinks for security reasons. Clicking such a link will either do nothing or result in a browser security error.
Why do Office Scripts fail to interact with local files?
Office Scripts are designed to run securely in a cloud environment and automate actions strictly within the Excel workbook itself. They do not have the necessary permissions to access your local Windows file system or launch local applications.
How can I request Microsoft to add this feature?
You can submit your feature request or feedback directly to the Microsoft development team via the official Microsoft Feedback portal at feedbackportal.microsoft.com.




