When a user uninstalls a third-party antivirus product, a very frequent problem with the toggle switch of Windows Defender’s real-time protection usually arises.
You may have recently installed and deleted an antivirus product, which is the most likely cause. A few system configurations from the deleted antivirus program are still present on the machine, preventing Windows Defender from taking over and defending the device in real time.
Another possible reason is if a particular piece of malware disabled Windows Defender on its own to avoid being discovered by the program.
Windows Defender Real Time Protection is a great security feature, but it can sometimes be disabled due to such causes. Solving this issue is very easy, you may follow the short procedure below to fix the real time protection toggle bar.
1. Click the Windows Start Button, then type cmd.
2. Right-click the Command Prompt and select “Run as Administrator” from the options.
3. Paste this into Command Prompt and press Enter:
REG DELETE “HKLM\SOFTWARE\Policies\Microsoft\Windows Defender” /v DisableAntiSpyware
4. A confirmation message will appear, type Yes to confirm.
Now the toggle bar for Windows Defender will be working once again. You may now enable real time protection.