VBA & Macro Problems

Fix Word VBA Out of Memory Error When Creating a Macro

Nimra MalikNimra Malik Nov 2, 2026 869 views

Question details

The user encounters an 'Out of Memory' error message when attempting to create or edit a VBA macro in Microsoft Word.

How to Fix Word VBA Out of Memory Error When Creating a Macro
Product
Microsoft Word (Microsoft 365)
Device & OS
not provided
Scenario
Creating a new macro within a Word document or the global Normal.dotm template.
Observed behavior
Microsoft Word displays an 'Out of Memory' error and fails to create the macro. Additionally, running an Online Repair for Office may result in the software unexpectedly uninstalling or disappearing from the desktop.
Before you start

Save your current documents and try launching Microsoft Word in Safe Mode (hold the CTRL key while clicking the Word icon) to determine if the error still occurs. If the macro works in Safe Mode, a third-party add-in is likely causing the issue.

Solution 1Recommended

Disable Interfering Word Add-ins

If you can successfully create macros in Safe Mode, a third-party add-in is likely conflicting with the VBA editor. Disabling add-ins will resolve the memory error.

Many third-party extensions, particularly those that integrate deeply with Word's drafting environment, can cause memory conflicts with the Visual Basic for Applications (VBA) compiler.

1
Open Add-in Options

Launch Microsoft Word normally. Click on 'File' in the top-left corner, select 'Options' at the bottom, and then click on 'Add-ins' in the left sidebar.

2
Manage COM Add-ins

At the bottom of the window, locate the 'Manage' dropdown menu. Select 'COM Add-ins' and click the 'Go...' button.

3
Disable and Test

Uncheck all active add-ins in the list and click 'OK'. Restart Word and attempt to create your VBA macro again. If it works, re-enable your add-ins one by one to identify the specific culprit.

Disable Interfering Word Add-ins
Add-in Isolation: Once you identify the problematic add-in, you can check the developer's website for an updated version that does not conflict with Word VBA.
Free Microsoft Office alternative

Try WPS Office for a Stable Document Creation Experience

If you are tired of dealing with missing applications, complex repair processes, or VBA crashes in Microsoft Word, consider switching to WPS Office. It provides a highly stable, resource-efficient environment for handling all your document tasks.

  1. 1. Download the Installer: Visit the official WPS Office website and click the free download button to get the lightweight installer.
  2. 2. Install WPS Office: Run the downloaded file and follow the straightforward setup instructions to install the suite in minutes.
  3. 3. Open Your Documents: Launch WPS Writer and open your existing .docx files directly. Your formatting and text will remain perfectly intact.
Excellent compatibility with Microsoft Word documents (.docx, .doc, .dotm).Lightweight architecture that prevents frustrating out-of-memory errors on older systems.Free to use with a familiar, easy-to-navigate interface that requires no learning curve.All-in-one suite combining Word, Excel, and PowerPoint alternatives in a single tabbed window.
microsoft office alternative - wps office

Frequently Asked Questions

Why am I getting an 'Out of Memory' error when I have plenty of RAM?

In Microsoft Word, an 'Out of Memory' error during VBA macro creation rarely indicates a physical lack of system RAM. Instead, it is usually caused by an internal memory leak triggered by a faulty COM add-in, a corrupted Normal.dotm template, or limitations within the 32-bit architecture of the Office application.

What is the Normal.dotm file in Word?

Normal.dotm is the default global template used by Microsoft Word to create new, blank documents. It stores your custom macros, styles, AutoText entries, and default formatting settings. If this file becomes corrupted, it can cause various errors, including VBA crashes.

Why did Microsoft Office disappear after running an Online Repair?

This is a known glitch with the Microsoft 365 installation engine. The Online Repair process actually uninstalls the current suite and attempts to download and reinstall fresh copies of the applications in the background. If the background download is interrupted by a network issue or an internal error, the applications are left uninstalled. You must then log into the Microsoft portal to download the installer manually.