If you share a computer with family members or roommates and store confidential or intimate information on your PC, the best thing you can do is put all those files in a hidden, password-protected folder.

There is no native Windows 10 method of password-protecting folders, but there is a little trick to creating a password-protected folder. It is not the most intuitive process in the world, but it can help us at a particular moment.

Create a text file with the name you want in the same directory where you will place the protected folder. For example: Protected Folder. Right-click on a blank space on your desktop and select New> Text Document.

Creation of a TXT document on the desktopCreation of a TXT document on the desktop

Now, rename the file as Protected Folder.

Creation of a TXTCreation of a TXT

Open the document and 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%==INPUT YOUR PASSWORD HERE 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

Substitute in the text INPUT YOUR PASSWORD HERE with the password that you want to protect the folder with. Once done, save the text file with the extension .bat. To do this, go to the menu File>Save As...

Option to save the TXT createdOption to save the TXT created

Make sure the file extension is .bat and select the file type All files. When you are done, press Save in the lower right corner.

Save the doc as a BAT fileSave the doc as a BAT file

You have just created the app that will let you generate and hide your new password-protected folder. Double-clicking on this BAT file will create an automatic folder for you to save all your files in.

New protected folder already createdNew protected folder already created

Once you have saved everything you need in it, double-click on the BAT file again. A window will open on the Windows screen asking if you want to hide the protected folder. Type Y as a synonym for Yes to do so, or N if the answer is no.

Confirmation window to hide the folderConfirmation window to hide the folder

When you confirm the operation, the folder will disappear from your sight. When you need it back, just press the BAT file twice again. That will open a new window where you will have to type the key and press Enter to make the folder visible again.

Enter the password to open the folderEnter the password to open the folder

Note that this will only work if you have the option to not show hidden folders enabled in Windows 10. But if these folders are visible, your protected folder will also be visible and all these steps will be useless.

How to password protect a folder with Lock-A-FoLdeR

The other alternative is to use specific software for this task. Many options are available, for example, Lock-A-FoLdeR. Click on the green Download button below to download your executable. Once in your possession, install the software as usual.

The first thing you will have to do is choose a master password to access the program.

To use LocK-A-FoLdeR we have to create a master passwordTo use LocK-A-FoLdeR we have to create a master password

You will have to do it in this first window, but also during a second window as a confirmation.

Type in your master passwordType in your master password

When you have the software interface in front of you, click on Lock a Folder.

Press Lock A FolderPress Lock A Folder

Locate the folder you want to protect with the file browser and click Ok at the bottom.

Locate the folder to be protected and press OKLocate the folder to be protected and press OK

From this moment on, the folder will be invisible and only accessible through this software. When you need to access its contents, open the program, enter the master password, and look just below the Lock A Folder button. You should see the folder path there. Select it and click under Unlock Selected Folder to make it visible again in your directories.

Unlocking a password-protected folderUnlocking a password-protected folder

Either of these two methods will serve to protect access to your folders with a password that only you know.