Skip to content

This guide isn’t available in Bahasa Indonesia yet, so we’re showing the original English version.

Windows

How to Disable Windows Defender Temporarily

You can turn off Microsoft Defender’s real-time protection for a short time in Windows Security. It turns itself back on automatically after a while or on restart. For a trusted program that keeps getting blocked, adding an exclusion is safer than turning protection off.

Updated
Time
3 minutes
Difficulty
Easy
Applies to
Windows

By Published Oct 6, 2026

Quick answer

  1. 1 Open Windows Security > Virus & threat protection.
  2. 2 Under Virus & threat protection settings, click Manage settings.
  3. 3 Turn off Real-time protection and confirm.
  4. 4 Do what you need, then turn it back on (Windows also re-enables it automatically).
On this page
  1. Before you start
  2. Turn off real-time protection
  3. Safer: add an exclusion instead
  4. Why does it keep turning back on?
  5. Troubleshooting
  6. Frequently asked questions

Before you start

  • Administrator access

Method 1 Turn off real-time protection

  1. Step 1: Open Windows Security

    Search for Windows Security in Start and open it.

  2. Step 2: Go to virus settings

    Click Virus & threat protection, then Manage settings under Virus & threat protection settings.

  3. Step 3: Switch it off

    Turn off Real-time protection and click Yes.

  4. Step 4: Turn it back on

    When you’re done, switch it on again. Windows turns it back on automatically after a short time or at the next restart.

Method 2 Safer: add an exclusion instead

Protection stays on for everything else. Remove the exclusion when you no longer need it.

  1. Step 1: Open Exclusions

    In Virus & threat protection > Manage settings, scroll to Exclusions and click Add or remove exclusions.

  2. Step 2: Add the item

    Click Add an exclusion and choose File, Folder or Process for the trusted program, such as a development folder or a game mod tool.

Why does it keep turning back on?

That’s intentional: Windows doesn’t allow Defender to stay off permanently unless another antivirus is installed. When you install a third-party antivirus, Defender switches itself to passive mode automatically. Tamper Protection also stops apps from changing Defender settings behind your back; leave it on.

Troubleshooting

The switch is greyed out

Your PC is managed by work/school, or another antivirus is active. Check Windows Security > Settings > Manage providers.

Defender deleted a file I need

Go to Virus & threat protection > Protection history, select the item and choose Restore, only if you’re sure it’s safe.

Frequently asked questions

Do I need another antivirus if I use Defender?

No. Microsoft Defender is a capable, free antivirus built into Windows.

Does disabling Defender improve gaming performance?

Barely. Defender already reduces activity during games. Turning it off isn’t worth the risk.

Summary

Turn off Real-time protection in Windows Security > Virus & threat protection > Manage settings only briefly and only for trusted software. An exclusion is the safer long-term fix.

Sources

Written by

James Chambo

Founder

James is the Founder and Senior Editor of OnlineHow with more than 20 years of experience in internet publishing.