4 Ways to Turn On or Off Microsoft Defender Real-time Protection

We have numerous options so you can choose the best way to enable or disable real-time protection.

1: Windows Security Setting
2: Edit the Registry or Use Registry Files
3: Group Policy Editor
4: PowerShell or Command Prompt

1: Windows Security Settings

Click on Windows Security in the system tray found in the lower-right corner of your screen. Click on Virus & threat protection and on the next screen, click on Manage settings under Virus & threat protection.

Toggle On or Off under Real-time protection. Click

Turning real-time protection back on is as easy as clicking on the Windows Security tray icon again and click Turn on. You can also click on the notification that popped up to quickly enable real-time protection again.

2: Registry Files

You can edit the registry.

Open the Registry Editor and go to HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender.

Right-click on the right window and select New > DWORD > 32-bit Value. Name the new DWORD DisableRealtimeMonitoring.

Set the Value data to 1 to disable and delete the DWORD you created to enable.

3: Group Policy Editor

Open Group Policy Editor. Windows 10 Home users can enable Group Policy Editor.

Expand Computer Configuration > Administrative Templates > Windows Components > Windows Defender Antivirus > Real-time Protection.

Double-click Turn off real-time protection. Click Enable to turn real-time protection off and Not configured to turn real-time protection on.

4: PowerShell or Command Prompt

There are two commands each to turn real-time protection on or off. Open either PowerShell or the Command Prompt.

While these commands have been around for years, they didn’t work for us when testing for this tutorial.

Command Prompt:
On – PowerShell Set-MpPreference -DisableRealtimeMonitoring 0orPowerShell Set-MpPreference -DisableRealtimeMonitoring $false

Off – PowerShell Set-MpPreference -DisableRealtimeMonitoring 1orPowerShell Set-MpPreference -DisableRealtimeMonitoring $true

PowerShell:
On – Set-MpPreference -DisableRealtimeMonitoring 0orSet-MpPreference -DisableRealtimeMonitoring $false

Off Set-MpPreference -DisableRealtimeMonitoring 1orSet-MpPreference -DisableRealtimeMonitoring $true

Ref: 4 Ways to Turn On or Off Windows Defender Real-time Protection – MajorGeeks