How to enable macros in Excel?

How to enable macros in excel

Macros are the set of small, simple computer programs that can be used to perform, record, and automate common repetitive tasks inside Excel. It can be run anytime when we need to perform tasks.

Macros are dangerous in terms of security levels because they can damage or delete files available on the hard drive and corrupt our Microsoft Office installation.

Note: By default, macros are disabled in Microsoft Excel.

Enable macros

Before enabling the macros in excel, make sure that enable only safe macros.

We use the following two methods to enable macros in excel -

Method 1: Enable macros using Developer Tab

Note: To create as well as enable macros in the Message Bar. First, we need to enable the Developer tab in the Ribbon.

Step 1: Add the developer tab in the Ribbon

  1. Launch a [Microsoft Excel] file.

  2. Click the File tab in the upper left corner of the Excel file, and then click the Options tab.

How to enable macros in excel

  1. Click the Customize Ribbon option in the Excel Options dialog box.

  1. A Customize the Ribbon window will appear on the screen. On the right side of the panel, click the Customize Ribbon option, click the Developer Tab under the Main Tabs , and click the OK button as shown in the screenshot below.

Now, you can see that the Developer tab appears on the Ribbon.

Step 2: Once the Developer tab will appear on the Ribbon, click the Developer Tab and click on the Macro security option in the Code section .

Step 3: A Trust Center dialog box will appear with the selected Macro Settings option. Click the Enable all macros (not recommended; potentially dangerous code can run) radio button under the Macro Settings section and then click on the OK button at the bottom of the screen.

Method 2: Enable macros via the Trust Center Setting

Steps to enable macros via the Trust Center Setting is listed below -

Note: We use the below steps to enable macros in Microsoft Excel 2010, 2013, 2016, and 2019.

Step 1: Open the Microsoft Excel file in which you want to enable macros.

Step 2: Click on the File tab at the top-left corner of the screen. A list of file options will appear on the screen. Click on the Options tab.

How to enable macros in excel

Step 3: An Excel Options dialog box will appear on the screen. Click on the Trust Center option at the left pane.

Step 4: Click on the Trust Center Settings button under the Microsoft Excel Trust Center section, as shown in the screenshot given below.

Step 5: A Trust Center dialog box appears on the screen in which click on the Macro Settings option in the left side pane.

Step 6: Click on the Enable all macros (not recommended; potentially dangerous code can run) radio button under the Macro Settings option, and then click on the OK button at the bottom of the Trust Center dialog box.

Step 7: At the bottom of the Excel Options dialog box, click the OK button.

Now, all macros will run on Microsoft Excel without the warning message.

Disable Macros

The following steps are used to disable Macros in a Microsoft Excel document -

Step 1: Open a Microsoft Excel document.

Step 2: Go to the File tab at the top left corner of the Excel document. A list of file options will appear on the screen in which click on the options .

Step 3: Click on the Trust Center option at the left pane of the Excel Options dialog box.

Step 4: Click on the Trust Center Settings button in the Microsoft Excel Trust Center .

Step 5: A Trust Center dialog box will appear on the screen with the Macro Settings option at the left side pane.

Step 6: Click on the Disable all macros without notification and click on the OK button at the bottom of the screen.

Now, you can see that macros are now disabled from Excel documents.