The Best Ways to Hide or Password Protect a Folder in Windows - Windows Basics

Latest

Tuesday, April 18, 2023

The Best Ways to Hide or Password Protect a Folder in Windows

There are many ways to protect folders and sensitive data, such as hiding them in hard-to-find locations, storing them in removable storage devices and putting them in safes, saving them in the cloud with strong passwords. But if you often have to access them, you will have to leave them on your computer, even in the most accessible places. Then, a more effective way to protect the home directory is to hide, password or encrypt.

In the following article, I will guide you through 5 ways to protect folders on Windows:

1. Hide any folder using Windows built-in option

Windows has a built-in tool for you to hide the folder you want to hide. This is a poor security method, not used to protect important data. You can also use this tool to hide folders that you find annoying.

1. Go to File Explorer and find the folder you need to hide

2. Right-click on the folder and select Properties (on Windows 11 select Show more options > Properties)

3. Click on the box Hidden and then click OK

To view the files again, all you need to do is on the Folder Options window, uncheck the boxes for Show hidden files, folders, and drives and Hide protected operating system files. Or you can click the Hidden items box in the View menu of File Explorer.

2. Turn a regular folder into a hidden system folder using Command Prompt

This way is a bit more difficult than the previous one, so of course the security will be higher. To do this successfully, you will have to work a bit with the Command Prompt command line window.

1. Press Windows Keys + R to open Run and then type cmd and Enter to open Command Prompt 

2. Type the following command into the Command Prompt:

attrib +s +h “C:\Users\User Name\Desktop\Name Folder”

3. After completing the command you press Enter and the folder will be hidden. Even if you unhide in Folders Options, it can't be found.

4. To unhide, you need to run the above command again but replace "+" with "-"

3. Encrypt files or folders without installing additional software

Encryption is an effective way to protect your files. Microsoft has built-in an encryption tool in Windows for you to easily protect your data.

1. Right-click on the file or folder to be encrypted and select Properties

2. Click the Advanced button

3. Click on Encrypt Contents to Secure Data and then click OK

4. Click Apply to finish

5. If the file is encrypted, the system will send a suggestion that you should encrypt both the file and its parent directory

6. After encryption, the file or folder will turn green

The only downside to this method is that it binds encryption to your user account. This means that other accounts on the same computer cannot open files or folders that you have encrypted. However, if you use the same account, this method will not work.

How to backup locked folder encryption key in Windows 10

Follow these steps to manually back up the keys for encrypted folders:

1. Press Windows key + R to open the Run command dialog, type certmgr.msc, and then select OK.

2. In the left pane, go to Personal store > Certificates.

3. Select all certificates for Encrypting File System.

4. Right-click the selected files, then go to All Tasks > Export.

5. Start the Certificate Export Wizard by selecting Next on the first screen.

6. Keep the defaults selected, then click Next again.

7. Check the box next to Password to enable password and fill in the text fields below. Select Next.

8. Choose where to save the PFX file and give it a name.

9. Select Next to review the information you have provided and select Finish to complete the export.

10. Select OK on the successful export prompt. If you need to use this certificate, simply open it from wherever you saved it in step 9 and follow the on-screen prompts.

4. How to hide and access hidden folders with .BAT . files

1. Before you start you must create a folder to store the folders that need to be protected. To do this you just need to create a folder in the usual way and give it any name.

2. Navigate to the folder you just created, open that folder and proceed to create a new Text Document by right-clicking any space in the folder, selecting New => Text Document.

3. Open the Text Document file you just created, copy and paste the code below into it:

cls
@ECHO OFF
title Folder Private
if EXIST "HTG Locker" goto UNLOCK
if NOT EXIST Private goto MDLOCKER
:CONFIRM
echo Are you sure you 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 Private "HTG Locker"
attrib +h +s "HTG Locker"
echo Folder locked
goto End
:UNLOCK
echo Enter password to unlock folder
set/p "pass=>"
if NOT %pass%== PASSWORD_GOES_HERE goto FAIL
attrib -h -s "HTG Locker"
ren "HTG Locker" Private
echo Folder Unlocked successfully
goto End
:FAIL
echo Invalid password
goto end
:MDLOCKER
md Private
echo Private created successfully
goto End
:End

Note: In the above code, replace PASSWORD_GOES_HERE with the password you want to set. Finally, in Save as type select All type, name the file as locker.bat.

4. Now you can delete the original text file.

5. Next, double click on the locker.bat file to open the file. It will now create a new folder named Private. This Private folder is where you can store all your important files and folders....

6. After moving the data to be secured to the Private folder, double-click the locker.bat file.

Immediately a command line dialog box will appear asking if you agree to hide this folder, just type “Y” and then press ENTER.

7. Once done, the Private folder will disappear.

8. If you want to access the Private folder, double click on the locker.bat file and proceed to enter the password you have set in the command line window and press ENTER.

How to view files?

1. To view the files again, all you need to do is on the Folder Options window, uncheck the boxes for Show hidden files, folders, and drives and Hide protected operating system files.

2. Then on the screen will appear a warning window as shown below:

If you accidentally forgot your password

If you accidentally forget your password or if you want to change it, all you need to do is right-click on the locker.bat file and select Edit and proceed to change the password.

The above method only helps to protect your sensitive files from prying eyes. Those who know this trick or are computer savvy can easily open the file you have hidden, then you need a real password setting tool for the folder. You can see 3 software that Quantrimang.com has introduced such as: Wise Folder Hider, Folder Guard, Secure Folder

Some frequently asked questions

How to lock a folder in Windows 10 to prevent deletion?

One option is to right-click the folder and select Properties > Security > Advanced > Disable Inheritance > Convert inherited permissions into explicit permissions on this object. Then, select a user from the list, choose Edit > Show advanced permissions > Type > Deny, and check the box next to Delete.

How to hide folder on PC and lock it yourself in Windows 10?

To hide files and folders in Windows 10, right-click on the folder and select Properties > General > Hidden > Apply > OK. Although you can prevent hidden files from showing by adjusting the File Explorer view, other users can easily show hidden items by changing this setting. A third-party tool to add password-protected keys and hide folders more efficiently.

No comments:

Post a Comment