Macros are disabled by default in Word because they can run hidden code
Word turns off macros by default because they are small programs that can do almost anything on your computer — including things you did not intend. A macro can delete files, steal passwords, or install malware. Microsoft blocks them to protect you from opening a document that looks normal but contains malicious code.
If you have a document you trust and need the macros inside it to work, you can turn them on. But you are making a choice to accept that risk. This guide explains what macros do, why Word blocks them, and the exact steps to enable them when you decide it is safe.
Key Takeaways
- Macros are disabled by default because they can run code that deletes files, steals data, or installs malware without your knowledge.
- You can enable macros for a single document using the yellow notification bar that appears when you open a file containing them.
- You can also change your macro security settings in Word's Trust Center, but this affects all documents you open going forward.
- Only enable macros in documents from people or sources you trust completely — a document that looks like a spreadsheet can still contain hidden code.
The fastest way: use the notification bar for one document
When you open a Word document that contains macros, a yellow notification bar appears near the top of the screen. It says "Security Warning: Macros have been disabled." To the right is a button that says "Enable Content."
Click "Enable Content" and the macros in that document will run. This is the safest approach because it only affects the one file you are working with right now. If you close the document and open a different one, macros will be disabled again unless you click the button again.
This method works for documents you receive from colleagues, templates you download, or files you create yourself. The notification bar appears every time you open the file, so you have to make the choice each time.
Changing macro security settings in the Trust Center
If you want to change how Word handles macros permanently, you go through the Trust Center. Open Word and click "File" in the top left corner. Then click "Options" at the bottom of the menu on the left side.
In the Word Options window, click "Trust Center" on the left side. Then click the button that says "Trust Center Settings." A new window opens with a list on the left side. Click "Macro Settings."
You will see four options. "Disable all macros without notification" is the default — Word blocks macros silently. "Disable all macros with notification" shows you the yellow bar. "Disable all macros except digitally signed macros" allows macros only if they come from a source you have marked as trusted. "Enable all macros" turns off all protections.
Most people should stay on the default or the second option. Changing to "Enable all macros" means any document you open can run code without asking you first — this is the same risk as disabling your antivirus software.
What "digitally signed" macros means
A digital signature is a way for someone to prove they wrote the code and that it has not been changed since they signed it. If a macro is digitally signed by someone you have marked as trusted, Word will run it automatically.
This is useful if you work with templates from your company or regular downloads from a vendor you know. You can mark that source as trusted once, and then their documents will work without the yellow bar appearing every time.
To mark a source as trusted, open a document with a signed macro. The notification bar will say "Security Warning: Macros have been disabled" but also offer an option to "Trust all documents from this publisher." Click that, and future documents signed by the same publisher will run macros without asking.
Why you should not enable macros in documents from unknown sources
Malware creators often hide code inside Word documents because people trust documents more than they trust email links or downloads. A file that looks like a simple form or a price list can contain a macro that steals your login information or installs ransomware.
If someone sends you a document you were not expecting, or if you downloaded something from a website you do not know well, do not enable macros. If you need the document to work, contact the person who sent it and ask them to explain what the macros do and why you need them.
Legitimate documents usually come with an explanation. If someone says "just enable macros, it will work," that is a sign to be cautious. Real colleagues and vendors know that macros are a security concern and will explain why they are necessary.
Macros in templates and add-ins are different
Word templates and add-ins can contain macros, but they are stored in different locations than regular documents. If you install a template or add-in from Microsoft Office or from your company, it may already be in a trusted location and will run without the notification bar.
You can see which locations Word trusts by going to File > Options > Trust Center > Trust Center Settings > Trusted Locations. If you download a template from an unknown website, do not move it to a trusted location. Keep it in your Downloads folder, where it will trigger the notification bar if it contains macros.
What to do if you need macros but do not trust the source
If someone sends you a document with macros and you need it to work but you are not sure about the source, ask them to explain what the macros do. A legitimate sender will tell you specifically — for example, "the macro formats the table automatically" or "it calculates the totals in column D."
If they cannot or will not explain, you have a few options. You can ask them to save the document in a format that does not support macros, like .pdf or .xlsx without macros. You can open it in a different program that does not run macros, like Google Docs or LibreOffice. Or you can ask your IT department or a trusted tech person to review the code before you enable it.
Frequently Asked Questions
Can I see what a macro does before I enable it?
Yes, but it requires opening the Visual Basic editor, which is technical. Press Alt + F11 to open it, then look for the macro name in the Project Explorer on the left. Most people should ask the document creator what the macro does instead of trying to read the code.
If I enable macros in one document, does it turn them on for all my documents?
No. Clicking "Enable Content" in the notification bar only affects that one file. The next time you open a different document with macros, you will see the notification bar again and have to choose again. Your Trust Center settings affect all documents, but the notification bar choice is per-file.
What is the difference between .docm and .docx files?
.docx is the standard Word format and cannot contain macros. .docm is the macro-enabled format. If someone sends you a .docm file, it definitely contains macros. If they send you a .docx, it should not, but always check the notification bar when you open it.
Can I disable macros again after I enable them?
Not in the same session. Once you click "Enable Content," the macros run for as long as the document is open. Close the document and reopen it, and the notification bar will appear again. If you changed your Trust Center settings to enable all macros, you would need to change them back to disable macros again.
Do macros work the same way in Excel and PowerPoint?
Yes. Excel and PowerPoint use the same notification bar and Trust Center settings as Word. The same security rules apply — macros are disabled by default, and you can enable them per-document or change your settings globally.