Batch unblock files downloaded from Internet in Windows 10

When you download files from the Internet, Windows adds zone information to it and stores it in the file's NTFS alternate steam. Windows 10 shows you a security warning every time you try to open it. Some file types are fully blocked from opening. SmartScreen, a security feature of Windows 10, causes this behavior. But even if SmartScreen is turned off, you still get a warning and need to unblock downloaded files. While you can unblock your files one by one as described here How to unblock files downloaded from Internet in Windows 10, it is a very time consuming operation. If you need to unblock a bunch of files downloaded from Internet in Windows 10, here is how you can do it.


When you try to open a file which was downloaded from the Internet, you see a warning like this: Windows 10 SmartScreen Warning

To avoid it and unblock all files in a folder in Windows 10, we need to use the PowerShell command line.

Let's say you want to unblock all downloaded files in your Downloads folder located inside the user profile. This folder is used by default by almost all apps like web browsers, download managers etc, so the files there are usually blocked. To unblock them all at once, you need to do the following:

  1. Open PowerShell as described in the following article: All ways to open PowerShell in Windows 10.
  2. Type the following command:
    dir c:\users\winaero\downloads -Recurse | Unblock-File

    Replace the "c:\users\winaero\downloads" portion with the actual path to your folder. Windows 10 batch unblock files with path

  3. Alternatively, you can navigate to that folder using the good old CD command as follows:
    cd c:\users\winaero\downloads

    Windows 10 navigate downloads folder Then, you can omit the folder path and execute the following command:

    dir -Recurse | Unblock-File

Windows 10 batch unblock downloaded files This PowerShell command does not produce any output. It works silently and very quickly.

Tip: You can open the PowerShell command window in the desired folder directly. All you need to do is click the Explorer File menu -> Open Windows Powershell -> Open Windows Powershell. See the following screenshot: Windows 10 downloads folder Windows 10 powershell command Windows 10 batch unblock downloaded files

That's it.

6 thoughts on “Batch unblock files downloaded from Internet in Windows 10

  1. Nutrynion

    Even more, as long as the Open Powershell is active when you click File, Open Powershell > Open Powershell (as it is greyed out of there is nothing in the folder) You can right click on it, and add it to your quick access toolbar making it a one click job.

    Reply
    1. Sergey Tkachenko Post author

      Nice tip, thanks!

      Reply
  2. Rick Grunwald

    While I am still on Win 8 … I have just shut smart screen off as I find it not that smart

    Reply
    1. Sergey Tkachenko Post author

      I agree about that Smart Screen feature.
      However, browsers add the blocking info to files in any case.
      Another confirmation will appear when you open a file.

      Reply
  3. Bo Cross

    Easier to use the environment variable – but it might affect all users?
    dir C:\Users\%username%\Downloads -Recurse | Unblock-File

    Reply
    1. Sergey Tkachenko Post author

      No, it won’t. It will process files only for your current user account.

      Reply

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.