Subscribe to Updates

    Get the latest creative news from FooBar about art, design and business.

    What's Hot

    Trollishly: 5 Ways to Start a New Trend on TikTok

    January 30, 2023

    How to Teach your Child to Program in Python

    January 30, 2023

    How to Enable “Fix problems using Windows Update” option in Windows 11 Settings

    January 27, 2023
    What's Hot

    Trollishly: 5 Ways to Start a New Trend on TikTok

    January 30, 2023

    How to Teach your Child to Program in Python

    January 30, 2023

    How to Enable “Fix problems using Windows Update” option in Windows 11 Settings

    January 27, 2023
    Facebook Twitter Instagram
    GeekerMag
    • Home
    • Windows
      1. Windows 11
      2. Windows 10
      3. View All

      How to Enable “Fix problems using Windows Update” option in Windows 11 Settings

      January 27, 2023

      Fix – Windows Terminal 1.16 Won’t open (Startup issue)

      January 27, 2023

      How to Display or Show Desktop Icons in Windows 11 (Desktop Shortcuts)

      January 27, 2023

      How to Add or Remove (Unpin) Widgets in Windows 11

      January 26, 2023

      Fix – Microsoft Store Error Code 0xC002001B in Windows 10 While Installing Apps

      May 21, 2022

      Fix: Chrome, Edge, Firefox Crashes with 0xc0000022 After Windows 11, 10 April 2022 Updates

      April 16, 2022

      How to Disable ‘Search Highlights’ in Windows 11 & Windows 10

      March 25, 2022

      How to Increase Virtual Memory Size in Windows 11 & 10

      March 15, 2022

      Trollishly: 5 Ways to Start a New Trend on TikTok

      January 30, 2023

      How to Teach your Child to Program in Python

      January 30, 2023

      How to Enable “Fix problems using Windows Update” option in Windows 11 Settings

      January 27, 2023

      Fix – Windows Terminal 1.16 Won’t open (Startup issue)

      January 27, 2023
    • Browser
      1. Microsoft Edge
      2. Google Chrome
      3. Firefox
      4. View All

      How to Automatically Hide Sidebar for Apps in Microsoft Edge

      January 24, 2023

      How to Split Screen in Microsoft Edge & Compare Two Tabs

      January 24, 2023

      Fix – Microsoft Edge creates shortcuts on the desktop after each update

      January 21, 2023

      Fix – Microsoft Edge v109 Printing issue due to Special (Umlaut) characters

      January 19, 2023

      How to Disable Windows 10 Upgrade Prompt in Google Chrome

      December 7, 2022

      Stop Chrome, Edge Spell Check feature from leaking Passwords

      September 20, 2022

      How to Take Full Page Screenshot in Chrome without Extension

      May 5, 2022

      How to Access or Disable Side Panel in Google Chrome

      March 27, 2022

      How to Automatically Reject All Cookies Banner on Sites in Firefox

      December 23, 2022

      How to Install Firefox v100 in Windows 7

      April 9, 2022

      How to Enable Close Tab Warning in Firefox 94

      October 27, 2021

      How to Restore Missing View Image Info Option in Firefox

      September 2, 2021

      Trollishly: 5 Ways to Start a New Trend on TikTok

      January 30, 2023

      How to Teach your Child to Program in Python

      January 30, 2023

      How to Enable “Fix problems using Windows Update” option in Windows 11 Settings

      January 27, 2023

      Fix – Windows Terminal 1.16 Won’t open (Startup issue)

      January 27, 2023
    • Gaming

      5 Cool Puzzle and Brain Teaser Games

      November 24, 2022

      4 Alternatives to Microsoft Solitaire You Should Try 

      June 29, 2022

      5 Best Equipment to Stream Your Game Live [Logitech, Tonor & so on..]

      April 6, 2022

      Twitch Set to Offer Income Incentives to Help Level the Playing Field

      March 9, 2022

      How to Stream Xbox One Games to a Windows 11 & 10 PC

      October 25, 2021
    • Best Of

      How to Teach your Child to Program in Python

      January 30, 2023

      What Should You Look at Before Choosing Automatic Captioning Software?

      April 20, 2022

      10 Best Windows 11 Laptop to Buy in 2022

      March 16, 2022

      5 Best Logo Maker Sites to Create a Logo in 2022

      January 9, 2022

      9 Best Apps to Track Your Habits & More Productive

      November 11, 2021
    • How to

      How to Make Coding Fun

      May 25, 2022

      How to Add Captions and Subtitles to Your YouTube Video

      April 25, 2022

      How to Enable or Disable New Gmail 2022 User Interface

      March 5, 2022

      Fix – Stop Edge from Hijacking/Opening PDF Files – (Workaround)

      February 21, 2022

      Three Tips to Help Organize Your Email Inbox

      December 22, 2021
    GeekerMag
    Home»How to»How to Password Protect a Folder in Windows 10 (Three Ways)
    How to

    How to Password Protect a Folder in Windows 10 (Three Ways)

    By Viney DhimanOctober 1, 2018Updated:June 18, 20213 Comments6 Mins Read
    Facebook Twitter Pinterest LinkedIn Tumblr Email
    Share
    Facebook Twitter LinkedIn Pinterest Email

    Want to hide folders from your family? Make them password protected. The following blog post will guide you how to Password Protect a folder in Windows 10.

    how to password protect a folder in windows 10
    Image: appducate.com

    Sometimes your computer has lots of sensitive information it can bank information, financial documents, family photos, or some personal picture of you with your girlfriend ????

    No doubt your data is secured, but it is always good to keep yourself on the safe side. Password protecting your folders having sensitive information add a necessary layer of security. Password protect a folder works like a virtual vault, which hides whatever is inside the folder.

    Contents show
    How to Password Protect a Folder in Windows 10
    1. Quick workaround (Batch Script)
    2. Zip Folder Lock
    3. Use Hide files and folder feature

    How to Password Protect a Folder in Windows 10

    Wondering how to create a password protected folder? It’s super easy to do. In upcoming lines, I’m going to teach possible ways to put a password on a folder.

    1. Quick workaround (Batch Script)

    Windows 10 with default settings, doesn’t allow users to set a password on a file, but with a quick workaround you can to do.

    All you need to do is write a batch script using a notepad. Here’s what you need to do:

    1. To get started you need to head over to the folder on which you want to put a password. For this tutorial, I’m creating a new folder named as ‘Test.’

    2. Open the folder by making a double click. Inside the folder, you need to create a new text file in which you need to type the code.

    create text file

    To create a text file, make right click on the empty space inside the folder and select New -> Text Document.

    How to Password Protect a Folder in Windows 10

    Inside text document, you need to copy-paste the following code:

    cls
    @ECHO OFF
    title Folder Locker
    if EXIST "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}" goto UNLOCK
    if NOT EXIST Locker goto MDLOCKER
    :CONFIRM
    echo Are you sure u want to Lock the folder(Y/N)
    set/p "cho=>"
    if %cho%==Y goto LOCK
    if %cho%==y goto LOCK
    if %cho%==n goto END
    if %cho%==N goto END
    echo Invalid choice.
    goto CONFIRM
    :LOCK
    ren Locker "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
    attrib +h +s "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
    echo Folder locked
    goto End
    :UNLOCK
    echo Enter password to Unlock folder
    set/p "pass=>"
    if NOT %pass%==your_password goto FAIL
    attrib -h -s "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}"
    ren "Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}" Locker
    echo Folder Unlocked successfully
    goto End
    :FAIL
    echo Invalid password
    goto end
    :MDLOCKER
    md Locker
    echo Locker created successfully
    goto End
    :End

    To set a password, you need to replace your password with “Your Password” in the next line:

     if NOT “%pass%==your_password” goto FAIL

    enter password

    After adding a password into the code, you need to save the file. For that, click on the File -> Save As. You will be asked to give a name to this file. Name it whatever you want, Locker sounds fine to me.

    save file

    Next, save the file with .bat extension. Since I’m naming it Locker so it will look like “Locker.bat.”

    Now, you need to double click on the BAT file which you created inside your folder using the above steps. This will create a new folder with the same name. This is going to be your password protected folder.

    How to Password Protect a Folder

    Copy-paste all your essential documents inside this folder. Once done, again double click on the Locker.bat file. A quick command prompt window will launch asking for your permission.

    Password Protect a Folder in Windows 10

    Type Y and hit enter. And your folder will instantly disappear.

    Now you might be wondering how to get the password protected folder back, right? Double click on the .bat file again. You will be asked to enter the password, and if you type the correct password, it will appear.

    Password Protect a Folder

    Note: This is a useful trick, but .bat can be changed from the computer. It means anyone aware of this workaround can easily unlock folder.

    2. Zip Folder Lock

    In the above workaround, we used a default text editor that comes preinstalled in every person of Windows OS. In this method, we will make use of popular file archiving tool named as 7-zip

    Usually, we use 7-zip to extract the file and unzip the folder. The good thing about this program is that also provides an option to password protect folders. Here’s what you need to do to password protect a folder:

    1. Download and install 7-zip using this link.

    2. Launch 7-zip File manager on your computer.

    3. Next, navigate to the folder for which you want to add a password and then click on the Add option available on the upper right corner.

    add

    This will open “Add to archive” window. Here, you need to head over to ‘Encryption section‘ and enter the secure password of your choice.

    Once you’re done, click on the OK button. In the same folder location, you will get a zip file of the same name (original folder).

    Password Protect a Folder in Windows 10

    As you have created a password protected zip file, you can move the original folder to trash (delete it).

    Note: It is suggested that always put all the important and sensitive data into a separate folder and then zip the file. If you don’t do that, then at the time of extractions all the file will be scattered.

    To extract the zip file, it is not mandatory that you need to a 7-zip program. You can use any archiving tool that supports zip file to extract your password protected folder.

    put password on a folder

    At the time of unzipping, you will be asked to enter the password. Enter the correct password, and you will be able to access the files inside the folder.

    3. Use Hide files and folder feature

    With the method discussed above, you learn how to create a password protected folder. With this method, you can add a layer of security by hiding the folder.

    Here’s what you need to do:

    1. Right click on the folder which you want to hide and select Properties.

    2. Next, head over to Attributes section and tick the box for Hidden.

    How to Password Protect a Folder in Windows 10

    When the “Confirm Attribute” dialog box opens up, make sure “Apply changes to this folder, subfolder, and files.”

    Click on the Apply button and then OK.

    Your folder will disappear in no seconds. Now you might be wondering, how to view it back, right? No worries, do this:

    3. In Windows File Explorer, you need to head over to View tab; you will find the option in the ribbon. Here, you need to tick box for “Hidden times“. This will instantly bring back the original folder.

    unhide folders in windows 10

    In case, you want to unhide the folder, then again launch the Folder Properties and uncheck the same option hidden option.

    Check out: How to View Hidden Files in Windows 10

    That’s it!

    These are some of the easy workarounds which you can use to create a password protected folder. It is upto you which method you want to employ.

    Find this my blog post how to put a password on a folder in Windows 10 useful? Is there any other method you’re using to put a password on a folder? Feel free to share your thoughts in the comments.

    Please do not hesitate to Contact me on Twitter if you want assistance with issue related to Windows 11, Windows 10, and Edge browser. I will try my best to assist you ASAP. (Follow me first and then PM your issue on Twitter)

    Buy us a coffee if you find information shared in this blog post useful. Mention ‘Coffee’ in Subject. So that I can thank you

    Windows 10
    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email
    Viney Dhiman
    • Website
    • Facebook
    • Twitter
    • Instagram
    • LinkedIn

    Himachali, Mechanical Engineer, Snooker Lover, Avid drinker of Scotch, Traveler, and Webmaster.

    Related Posts

    How to Make Coding Fun

    May 25, 2022

    How to Add Captions and Subtitles to Your YouTube Video

    April 25, 2022

    How to Enable or Disable New Gmail 2022 User Interface

    March 5, 2022

    Fix – Stop Edge from Hijacking/Opening PDF Files – (Workaround)

    February 21, 2022
    View 3 Comments

    3 Comments

    1. the economy on March 6, 2020 9:41 pm

      Asking questions are truly nice thing if you are not understanding anything entirely, except this article offers nice
      understanding yet.

      Reply
    2. Charles on April 9, 2020 6:19 am

      I found this Bat file to password a folder long time ago and I understood 99%, the 1% I could not get working is the usage of

      attrib -h -s “Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}”
      and
      ren “Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}”

      I have found out this Control Panel was used in Windows version prior to Windows 10 I have now. I searched the C: drive in it’s entirely and did not find anything existing. Also with today’s PC manufactured the D: drive is solely for OS and the D: drive is for all the user folders I want to Password protect. This requires for the Control Panel to be totally qualified if it exist on the C: drive. What can you tell me about the reason for the usage of this Control Panel file. Once I resolve this issue I believe this batch file will work as advertised. So far I have spent a ton of hours with this because there is not much else I could find to do this. Your attention to this matter will be greatly appreciated 2020 04 08 at 1750 hrs Charles

      Reply
      • Alex on May 10, 2020 11:19 pm

        It works, I just tested it.

        The piece of code you are referring to is a windows registry edit, to tell windows how to display the folder.

        Reply

    Leave A Reply Cancel Reply

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

    Download Windows 11 Native Screen Recording Tool
    Our Picks

    How to Enable “Fix problems using Windows Update” option in Windows 11 Settings

    January 27, 2023

    Fix – Windows Terminal 1.16 Won’t open (Startup issue)

    January 27, 2023

    How to Display or Show Desktop Icons in Windows 11 (Desktop Shortcuts)

    January 27, 2023

    How to Add or Remove (Unpin) Widgets in Windows 11

    January 26, 2023
    • Facebook
    • Twitter
    • Pinterest
    • Instagram
    • YouTube

    Subscribe to Updates

    Get the latest creative news from FooBar about art, design and business.

    Need Support?

    Please do not hesitate to Contact me on Twitter if you want assistance with issue related to Windows 11, Windows 10, and Edge browser. I will try my best to assist you ASAP. (Follow me first and then PM your issue on Twitter)

    Help Us Grow!

    Buy us a coffee if you find information shared in this blog post useful. Mention ‘Coffee’ in Subject. So that I can thank you

    Do you find the information shared on our blog useful? You might want to check Hot Deals on Amazon for your next purchase. With this, you support our site and the prices will remain the same for you ( you don't need to pay any extra amount) We appreciate your support, Thank you!

    Facebook Twitter Instagram Pinterest Vimeo YouTube
    • About
    • Contact
    • Privacy Policy
    • TOC
    © 2023 All Rights Reserved | GeekerMag

    Type above and press Enter to search. Press Esc to cancel.