How to Enable or Disable Microsoft Defender Antivirus in Windows 11
This guide explains how to manage Microsoft Defender Antivirus in Windows 11 on your Windows 11 computer.
Microsoft Defender is the free security tool built into Windows. It guards your computer against viruses and other digital dangers. It runs in the background to watch your files and keep your data safe.
Why do this? Sometimes, you may need to turn it off to install a specific program or run a tool that the scanner accidentally blocks.
What happens when done? Your computer will stop scanning for threats. You will be at a much higher risk of catching viruses or malware.
Note: You must have administrator privileges to follow these steps.
How to Change Microsoft Defender Settings
Microsoft suggests keeping this feature turned on at all times. If you must change it, follow these steps carefully.
Open the Start menu and search for Edit group policy. Click it to open the Local Group Policy Editor.

In the list on the left, click through this path: Computer Configuration > Administrative Templates > Windows Components > Microsoft Defender Antivirus.

On the right side, find the setting named Turn off Microsoft Defender Antivirus and double-click it.

To turn the antivirus off, select Enabled. To turn it back on later, select Not configured.
Click OK and close the window.

Close the Local Group Policy Editor.
Change Settings Using the Command Prompt (Admin Required)
Open the Windows Terminal app as an administrator and run the commands below:
To enable Defender:
reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender" /v DisableAntiSpyware /f
To disable Defender:
reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender" /v DisableAntiSpyware /t REG_DWORD /d 1 /f
Summary
Microsoft Defender is your computer’s main line of defense. You can turn it on or off using the Local Group Policy Editor or the command line, but you must have administrator rights to do so. Turning it off is not recommended because it stops all automatic protection. If you must disable it for a specific task, turn it back on as soon as you are finished to keep your system safe. Tamper Protection Local Group Policy Editor
Was this guide helpful?
Leave a Reply