Skip to content
Follow
Windows

How to Exclude Files from Microsoft Defender on Windows 11

Richard
Written by
Richard
Oct 24, 2021 Updated Sep 15, 2026 2 min read
How to Exclude Files from Microsoft Defender on Windows 11
How to Exclude Files from Microsoft Defender on Windows 11

Microsoft Defender (the built-in security app on Windows 11 that scans your system for viruses) occasionally blocks safe programs and games by mistake. Adding a file exclusion tells the antivirus to ignore a specific file, folder, or running process so you can run your apps without constant interruptions.

Advertisement

Setting up exclusions stops Defender from checking those specific items while keeping the rest of your computer protected against real threats.

⚡ Quick Answer

Exclude files from Microsoft Defender by opening Windows Security, navigating to Virus & threat protection, then Manage settings, and finally Add or remove exclusions. Click Add an exclusion and choose the type of item to exclude.

Advertisement

How to add exclusions in 🪟 Windows 11

To exclude files Microsoft Defender skips during a scan, you need to use the Windows Security app. This built-in tool lets you stop the antivirus from checking specific folders or files on your computer. You can set this up in just a few clicks by opening the virus protection settings and adding your chosen items to the ignore list.

1. Click the Start button and type Windows Security. Open the app.

Windows Security app open on Windows 11
windows 11 windows security app open

2. Click Virus & threat protection. Then, click Manage settings.

Virus and threat protection settings in Windows Security
windows 11 windows security app virus and threat protection

3. Scroll down and click Add or remove exclusions.

Advertisement
Adding an exclusion in Windows Security on Windows 11
windows security add exclusion on windows 11

4. Click the Add an exclusion button and choose File, Folder, File type, or Process.

Add an exclusion option in Windows Security app
windows 11 security app add an exclusion

5. Select your item and confirm the change.

Exclusion settings for Microsoft Defender on Windows 11
add exclusion to microsoft defander

Comparison of Exclusion Methods

MethodBest ForDifficulty
Windows Security AppHome usersEasy
PowerShellAdvanced usersMedium
Intune/GPOIT AdministratorsHigh

Advanced Configuration and Enterprise Management

Admins managing multiple PCs can set up Microsoft Defender exclusions across a network using Intune, Configuration Manager, or PowerShell. These tools let you apply rules to many computers at once or use wildcard paths to skip groups of files. This saves you from having to set up exclusions manually on every single machine in your network.

Add-MpPreference -ExclusionPath "C:\Projects\Development"

Wildcards target entire groups of files when broader coverage is necessary. For instance, using C:\Projects\*\bin will exclude the 'bin' folder inside every subfolder of your projects directory.

Advertisement

Validation and Verification

Checking whether your Microsoft Defender exclusions work properly requires running specific commands in PowerShell or using the built-in scan utility. These tools let you view every ignored path currently on your system and test manual scans to make sure Defender actually skips your chosen files.

Get-MpPreference | Select-Object -ExpandProperty ExclusionPath

This command lists all paths currently ignored by Defender. The MpCmdRun.exe tool also performs manual scans and verifies that excluded files skip scanning during scheduled security checks.

Best Practices for Security

Exclusions introduce a security risk to the operating system. Apply them only when addressing verified performance issues or false positives. Avoid excluding entire drives like C:\ or broad system directories. File-specific exclusions provide better protection than folder-wide exemptions.

Summary

Configuring Microsoft Defender exclusions accelerates trusted applications, and Windows Security or PowerShell handles the setup process.

Was this guide helpful?

100% of readers found this helpful (2 votes)

📬 Get new Windows tips in your inbox
One email when we publish something worth your time. No spam, unsubscribe anytime.
Tags: #Windows 11
Was this helpful?
Richard

About the Author

Richard

Tech Writer, IT Professional

Richard, a writer for Geek Rewind, is a tech enthusiast who loves breaking down complex IT topics into simple, easy-to-understand ideas. With years of hands-on experience in system administration and enterprise IT operations, he’s developed a knack for offering practical tips and solutions. Richard aims to make technology more accessible and actionable. He's deeply committed to the Geek Rewind community, always ready to answer questions and engage in discussions.

3150 articles → Twitter
Advertisement

📚 Related Tutorials

How to Check Microsoft Defender Updates in Windows 11
Windows How to Check Microsoft Defender Updates in Windows 11
How to Optimize Microsoft Defender CPU Usage in Windows 11
Windows How to Optimize Microsoft Defender CPU Usage in Windows 11
How to Enable or Disable Windows Security Notifications in Windows 11
Windows How to Enable or Disable Windows Security Notifications in Windows 11
How to Change PowerShell Execution Policies in Windows 11
Windows How to Change PowerShell Execution Policies in Windows 11

No comments yet — be the first to share your thoughts!

Leave a Comment

Your email address will not be published. Required fields are marked *