How to Restore Default VBA Editor Window Layout in Excel
Question details
The user wants to revert the Visual Basic Editor (VBE) workspace back to its default layout after the Project Explorer, Properties, and Code windows became undocked or scattered.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- Managing macros and editing VBA code where the workspace windows have accidentally been moved, closed, or detached from their default side-by-side structure.
- Observed behavior
- The VBE panes (Project Explorer, Properties, and Code window) are floating, overlapping, or appearing one below another instead of snapping to the default docked layout.
Ensure you have saved your current Excel workbook containing the VBA project to prevent any accidental code loss while rearranging the editor windows.
Reset Docking Options and Arrange Windows Manually
This solution restores the standard arrangement by verifying docking settings in the VBE Options menu and manually snapping the windows back into their designated areas.
Excel does not have a single 'reset to default' button for the Visual Basic Editor layout. You must ensure the docking settings are active and then drag the panes back to their proper docking edges.
Launch your Excel workbook and press 'Alt + F11' on your keyboard to open the Visual Basic Editor window.
In the top menu bar, click on 'Tools' and select 'Options'. Navigate to the 'Docking' tab and ensure the checkboxes for 'Project Explorer' and 'Properties Window' are checked. Click 'OK'.
If the windows are not currently visible, press 'Ctrl + R' to display the Project Explorer, and press 'F4' to open the Properties window.
Click and hold the title bar of the Project Explorer. Drag it to the far left edge of the VBE screen until you see a faint outline indicating it will snap into place, then release your mouse.
Grab the title bar of the Properties window and drag it directly beneath the docked Project Explorer on the left side until it snaps into the lower-left corner.
Open a module to reveal the Code window, then click its maximize button in the upper right corner so it fills the remaining blank space on the right side of the screen.

Try WPS Office for a Lightweight and Seamless Spreadsheet Experience
If you are frustrated with complex layout management and interface glitches in Microsoft Excel, consider switching to WPS Office. It provides a lightweight, highly compatible alternative for handling spreadsheets with a familiar user interface.

Frequently Asked Questions
Why won't my VBA windows dock when I drag them?
If your VBE windows refuse to dock and remain floating no matter where you drag them, the docking feature is likely disabled. Go to 'Tools' > 'Options' > 'Docking' in the VBA Editor and make sure the checkboxes for your specific windows are ticked.
Is there a shortcut or button to reset the Excel VBA Editor to factory defaults?
No, Excel does not feature a native 'Reset Layout' button for the Visual Basic Editor. The layout must be reconstructed manually by enabling docking options and dragging the panes to the left and right sides of the application window.
How do I find the Project Explorer if it is accidentally closed?
You can quickly reopen a closed Project Explorer by pressing 'Ctrl + R' on your keyboard while inside the VBA Editor. Alternatively, you can click on 'View' in the top menu and select 'Project Explorer'.




