To help prevent spyware and other potentially unwanted software from running on your computer, turn on Windows Defender real-time protection and select all real-time protection options. You will be notified if programs attempt to install themselves or run on your computer. For more information, see Understanding Windows Defender real-time protection.
Open Windows Defender by clicking the Start button . In the search box, type Defender, and then, in the list of results, click Windows Defender.
Click Tools, and then click Options.
Click Real-time protection, and then select the Use real-time protection (recommended) check box.
Select the options you want, and then click Save.
If you're prompted for an administrator password or confirmation, type the password or provide confirmation.
To help protect your privacy and your computer, we recommend that you select all real-time protection options.
To turn off real-time protection, clear the Use real-time protection (recommended) check box.