Fix Windows Defender (Setting is managed by your administrator)

This command took a really long time to figure out. I’m not sure it will work for you, don’t blame me if it will mess up your computer. It worked fine for me on Windows 10. I guess it will work on ~Windows 8-8.1 too, maybe even Windows 7.

This setting is managed by your administrator Windows Defender

Copy the following command and paste it in the Command Prompt by right clicking with the mouse. It will paste it directly when you rightclick, now you only have to press Enter.
Hopefully it will change directory to your username directory, then it will store a backup of the registry keys if something goes wrong.
Then it will try to delete the registry keys.

Close down Windows Security Settings and any other Windows settings stuff if you got that open and Regedit too. I don’t really know if it matters, but do it anyway.

Start the Command Prompt as Administrator. It won’t work unless you run it as Administrator.

Here the command to copy and paste:

echo off && cls && echo Creating Registry Backup: %USERPROFILE%\WindowsDefender-Reg-Backup.reg && cd %USERPROFILE% && reg export "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender" "WindowsDefender-Reg-Backup.reg" && echo. && echo Deleting HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender && reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender" && echo. && echo Done. Check if you can turn on the Windows Defender settings now. && echo. && Made by && echo. && echo on

If everything went successful, restart your computer. (You might have to reconnect your USB-devices like keyboard and mouse unless they work.)

Go into the Windows Defender settings and see if you can turn everything on.