A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data
For Office 2024 on Windows, use one of these supported paths:
- Enable a macro for a specific file
- Open the file.
- If the yellow security warning appears, select Enable Content.
- In the Security Warning dialog, select Yes to make the document trusted.
- This enables macros for that document.
- Change macro settings in the app
- Go to File > Options > Trust Center > Trust Center Settings > Macro Settings.
- Choose the setting that matches the need:
- Disable all macros without notification
- Disable all macros with notification
- Disable all macros except digitally signed macros
- Enable all macros (not recommended, potentially dangerous code can run)
- In Excel, these options are shown as VBA macros options.
- These settings apply only to the current Microsoft 365 app, not all Office apps.
- Stop repeated warnings for trusted files
- Use Enable Content once to make the document trusted, or
- Store trusted files in a Trusted Location so Office does not check them through Trust Center.
- If the file came from the internet and macros are still blocked
- Office can block macros from files obtained from the internet by default.
- If that policy is Disabled or Not Configured in older behavior, users can see the warning and use Enable Content.
- If the device is managed by work or school, an administrator might prevent changing macro settings.
- If the goal is to stop the warning entirely
- In Office on Windows, the warning behavior is controlled through Trust Center macro settings.
- Disable all macros with notification is the default prompt-based option.
- Enable all macros stops macro prompts, but it is not recommended because potentially dangerous code can run.
Important security note:
- Microsoft advises not to broadly lower Trust Center security unless the files and source are trusted.
- Macros are not required to view or edit the file.