You want to add your most-used commands to the right-click context menu in Word to speed up your editing workflow. The right-click menu is controlled by the Normal.dotm global template and cannot be changed directly in Word’s user interface. This article explains how to modify the context menu using the built-in Customize Ribbon dialog and the Quick Access Toolbar, which also affect right-click behavior indirectly, and then shows the advanced method of editing the Normal.dotm template directly to add or remove commands from the right-click menu.
Key Takeaways: Customizing the Right-Click Menu in Word
- File > Options > Quick Access Toolbar > Customize > Right-click menu: Use the “Choose commands from” dropdown to select “All Commands” then pick the specific right-click menu (e.g., “Context Menu | Text”) to add commands.
- Normal.dotm template editing via Developer tab > Visual Basic: Open the VBA editor, locate the Normal project, and modify the context menu XML in the ThisDocument module to add or remove menu items.
- Quick Access Toolbar as a workaround with right-click: Add commands to the QAT and then right-click on the QAT to find a limited set of commands that can be added to the right-click menu via the Customize dialog.
How the Right-Click Menu Works in Word
The right-click context menu in Word is a dynamic set of commands that changes depending on what you click on: selected text, a table cell, an image, a shape, a hyperlink, or an empty area of the document. Each context menu is stored as a separate menu bar in Word’s command customization system. These menus are not exposed in the Ribbon or Quick Access Toolbar customization dialogs by default. You must select the specific context menu from the “Choose commands from” dropdown in the Customize dialog to see its contents.
The customization data is stored in the Normal.dotm global template. Any changes you make to a context menu are saved into that template and apply to all documents you open. If you delete or rename Normal.dotm, your customizations reset to the Word default. This means you can back up your custom context menus by copying Normal.dotm to another folder.
Prerequisites for Customizing the Right-Click Menu
Before you start, make sure you have the Developer tab visible on the Ribbon. To enable it, go to File > Options > Customize Ribbon, then check the box for “Developer” in the right panel and click OK. You need the Developer tab to access the Visual Basic Editor and to save macro-enabled templates. You also need to know the exact name of the context menu you want to edit. Common context menu names include “Context Menu | Text”, “Context Menu | Table”, “Context Menu | Picture”, and “Context Menu | Hyperlink”.
Method 1: Add Commands to a Right-Click Menu Using the Customize Dialog
This method uses the same dialog that customizes the Ribbon and Quick Access Toolbar. The dialog contains a hidden list of all context menus. You must select the correct context menu from a dropdown list to see its current commands and add new ones.
- Open the Customize Keyboard and Menu Dialog
Click File > Options > Quick Access Toolbar. At the bottom of the Quick Access Toolbar options, click the “Customize” button next to “Keyboard shortcuts”. This opens the Customize Keyboard dialog. Close that dialog by clicking Cancel, but do not close the main Options dialog yet. - Switch to the Context Menu List
In the Quick Access Toolbar options, find the dropdown labeled “Choose commands from”. Click it and scroll to the very bottom of the list. Select “All Commands” first to populate the list of available commands. Then, in the same dropdown, you will see entries like “Context Menu | Text”, “Context Menu | Table”, “Context Menu | Picture”, etc. Select the one that matches the menu you want to customize. - Add a Command to the Right-Click Menu
After selecting the context menu, the list box below shows the current commands on that menu. To add a new command, go back to the “Choose commands from” dropdown and select “All Commands” again. Scroll through the alphabetical list of commands until you find the one you want. Click the command to select it, then click the “Add >>” button between the two list boxes. The command appears in the right-click menu list. - Rearrange or Remove Commands
In the right-click menu list, you can select a command and use the up and down arrows to reorder it. To remove a command, select it and click the “<< Remove" button. You cannot remove built-in commands that are grayed out. Those are required by Word. - Save and Test the Custom Menu
Click OK to close all dialogs. Right-click on a blank area of a document to see your changes. If you customized the “Context Menu | Text” menu, select some text and right-click to test the new commands.
Method 2: Remove or Add Commands by Editing Normal.dotm Directly
This method gives you full control over the right-click menu structure. You edit the XML code inside the Normal.dotm template using the Visual Basic Editor. This is the only way to remove built-in commands that are grayed out in the Customize dialog, or to add custom macros and special separators.
- Open the Normal.dotm Template in the VBA Editor
On the Developer tab, click “Visual Basic” to open the VBA editor. In the Project Explorer pane on the left, expand “Normal” > “Microsoft Word Objects” and double-click “ThisDocument”. - Insert the Custom UI XML Code
In the ThisDocument code window, paste the following XML structure. This example removes the default “Smart Lookup” command from the text context menu and adds a custom command that runs a macro named “MyMacro”.<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui">
<contextMenus>
<contextMenu idMso="ContextMenuText">
<button idMso="SmartLookupShow" visible="false"/>
<button id="MyCustomButton" label="Run My Macro" onAction="MyMacro" insertBeforeMso="Cut"/>
</contextMenu>
</contextMenus>
</customUI> - Change the Context Menu ID and Commands
Replace “ContextMenuText” with the ID of the menu you want to edit. Common IDs: ContextMenuText (text), ContextMenuTable (table), ContextMenuPicture (picture), ContextMenuHyperlink (hyperlink). Use button idMso to hide built-in commands, and button id with onAction to add custom macros. The insertBeforeMso attribute places your button before a specific built-in command, such as “Cut”. - Save the Template and Restart Word
Save the Normal.dotm template by clicking File > Save Normal.dotm in the VBA editor, or press Ctrl+S. Close Word completely and reopen it. Right-click on text to see the customized menu. The “Smart Lookup” command is hidden, and your custom button appears.
Common Issues When Customizing Right-Click Menus
The Custom Dialog Does Not Show Any Context Menus
If you cannot see “Context Menu | Text” or similar entries in the “Choose commands from” dropdown, you are likely looking at the wrong dialog. Go to File > Options > Quick Access Toolbar, then click the “Customize” button near the bottom. The dropdown that lists “Context Menu” entries only appears in that secondary Customize dialog, not in the main Options pane.
Changes Do Not Appear After Adding a Command
Word caches the context menu customization in Normal.dotm. If you do not see your changes, close all Word windows and reopen the application. If the changes still do not appear, check that you selected the correct context menu in the Customize dialog. For example, adding a command to “Context Menu | Text” does not affect the menu that appears when you right-click an image.
Custom Menu Disappears After an Office Update
Office updates sometimes reset the Normal.dotm template to its default state. To prevent losing your customizations, back up the Normal.dotm file. Its default location is %appdata%\Microsoft\Templates. Copy Normal.dotm to a different folder. If an update erases your changes, close Word, copy your backup into the Templates folder, and restart Word.
Right-Click Menu Customization: Customize Dialog vs VBA XML Editing
| Item | Customize Dialog Method | VBA XML Editing Method |
|---|---|---|
| Ease of use | No coding required, simple point-and-click | Requires basic XML knowledge and VBA editor access |
| Add custom macros | Cannot add macros directly, only built-in commands | Can add any macro or custom function via onAction |
| Remove built-in commands | Cannot remove grayed-out (locked) commands | Can hide any command using visible=”false” |
| Persistence across updates | Stored in Normal.dotm, may reset after major updates | Same storage, but XML changes more likely to survive updates |
| Number of menus you can edit | All context menus available in the dropdown list | All context menus, plus custom menus you define |
Customize Dialog Method is best for users who want to add or remove standard commands without writing code. VBA XML Editing is required for advanced users who need to run macros or hide locked built-in buttons.
Conclusion
You can now add, remove, and reorder commands on any right-click context menu in Word using either the Customize dialog or the VBA XML method. Start by backing up your Normal.dotm template to %appdata%\Microsoft\Templates. For quick changes, use the Customize dialog under File > Options > Quick Access Toolbar and select the specific context menu from the “Choose commands from” dropdown. For full control, edit the XML in ThisDocument inside the VBA editor and use the idMso attribute to hide built-in commands like SmartLookupShow. After customizing, test each menu by right-clicking on text, tables, images, and hyperlinks to confirm your changes apply correctly.