This tutorial will show you different ways on how to unblock files downloaded from the Internet depending on how they were blocked in Windows 11.
When you download files from the Internet, Windows 11 shows you a security warning every time you try to open it by default. Some file types are blocked from opening.
The Attachment Manager is included in Windows to help protect your PC from unsafe attachments that you might receive with an e-mail message and from unsafe files that you might save from the Internet. If the Attachment Manager identifies an attachment that might be unsafe, the Attachment Manager prevents (blocks) you from opening the file, or it warns you before you open the file.
It uses the IAttachmentExecute application programming interface (API) to find the file type, to find the file association. When one of these applications saves a downloaded file on a disk formatted with NTFS, then it updates the metadata for the file with the zone it was downloaded from. The metadata is saved as an Alternate Data Stream (ADS). If you wish to unblock a downloaded file, you can do so by right-clicking it, selecting Properties and clicking on Unblock.
The following determine whether you are prevented from opening the file or whether you are warned before you open the file:
- The type of program that you are using.
- The file type that you are downloading or trying to open
- The security settings of the Web content zone that you are downloading the file from.
- Internet
- Local intranet
- Trusted sites
- Restricted sites
- High Risk – If the attachment is in the list of high risk file types and is from the restricted zone, Windows blocks the user from accessing the file. If the file is from the Internet zone, Windows prompts the user with a Windows Security Warning: Windows found that this file is potentially harmful. To help protect your computer, Windows has blocked access to this file.
- Moderate Risk – If the attachment is in the list of moderate risk file types and is from the restricted or Internet zone, Windows prompts the user with a warning: "The publisher could not be verified. Are you sure you want to run this software?".
- Low Risk – If the attachment is in the list of low risk file types, Windows will not prompt the user before accessing the file, regardless of the file’s zone information.
- Option One: Unblock File(s) using Context Menu
- Option Two: Unblock File in Properties
- Option Three: Unblock and Open File in Open File - Security Warning
- Option Four: Unblock and Open App or File in Microsoft Defender SmartScreen Warning
- Option Five: Unblock File in PowerShell
- Option Six: Unblock All Files in a Folder in PowerShell
- Option Seven: Unblock All Files in a Folder and Subfolders in PowerShell
This option is only available if you add the Unblock context menu.
1 Right click on a file or folder, click/tap on Show more options, and click/tap on Unblock. (see screenshots below)
1 Right click or press and hold on the blocked file, and click/tap on Properties.
2 In the General tab, check the Unblock box at the bottom, and click/tap on OK. (see screenshot below)
If you do not see a Unblock checkbox, then the file is not blocked.
The Open File - Security Warning prompt is a security measure that will ask for your permission before opening a file on your PC that came from an unknown source such as the Internet or another PC.
1 Open or run the blocked file to trigger a Open File - Security Warning prompt.
2 In the Open File - Security Warning prompt, uncheck the Always ask before opening this file box, and click/tap on the Open or Run button. (see screenshots below)
Microsoft Defender SmartScreen helps keep your PC safer by warning you before running unrecognized apps and files downloaded from the Internet.
1 Open or run the blocked app or file to trigger Microsoft Defender SmartScreen.
2 Click/tap on the More info link. (see screenshot below)
3 Click/tap on the Run anyway button. (see screenshot below)
1 Open Windows Terminal or an elevated Windows Terminal depending on if your user account has access rights to where the folder containing the blocked file is located, and select Windows PowerShell.
2 Type the command below into PowerShell, and press Enter. (see screenshot below)
unblock-file -path "full path of blocked file"
Substitute full path of blocked file in the command above with the actual full path of the blocked file (with file extension) that you want to unblock.
For example: unblock-file -path "C:\Users\Brink\Downloads\Turn_On_Use_check_boxes_to_select_items.bat"
3 When finished, you can close Windows Terminal if you like.
1 Open Windows Terminal or an elevated Windows Terminal depending on if your user account has access rights to where the folder containing the blocked files is located, and select Windows PowerShell.
2 Type the command you want to use below into PowerShell, and press Enter. (see screenshot below)
(without confirmation prompt)
get-childitem "full path of folder" | unblock-file
OR
(with confirmation prompt per blocked file)
get-childitem "full path of folder" | unblock-file -confirm
Substitute full path of folder in the command above with the actual full path of the folder that contains the blocked file(s) you want to unblock.
For example:
get-childitem "C:\Users\Brink\Downloads" | unblock-file
OR
get-childitem "C:\Users\Brink\Downloads" | unblock-file -confirm
3 When finished, you can close Windows Terminal if you like.
1 Open Windows Terminal or an elevated Windows Terminal depending on if your user account has access rights to where the folder containing the blocked files is located, and select Windows PowerShell.
2 Type the command you want to use below into PowerShell, and press Enter. (see screenshot below)
(without confirmation prompt)
get-childitem "full path of folder" -recurse | unblock-file
OR
(with confirmation prompt per blocked file)
get-childitem "full path of folder" -recurse | unblock-file -confirm
Substitute full path of folder in the command above with the actual full path of the folder that contains the blocked file(s) you want to unblock.
For example:
get-childitem "C:\Users\Brink\Downloads" -recurse | unblock-file
OR
get-childitem "C:\Users\Brink\Downloads" -recurse | unblock-file -confirm
3 When finished, you can close Windows Terminal if you like.
That's it,
Shawn Brink