[How To] Password Protect A Folder Without Using Any Third Party Software

If you own a multi-user computer, you will always feel the necessity to password protect your important data so that other users will not have a direct access to it. If you want to lock or password protect your folders, consider using this free software (Secure Folder) to do it. It is easy to configure and use. However, if you are one of those who thinks you get all these sort of things worked on your Windows with tweaks, here is a classic (has been around since the days of Windows XP!) trick which allows you to lock (using a password) and make the folder invisible in Windows 7, Windows Vista and of course Windows XP. Follow these steps:

Steps:

1. Open notepad and type the following code saved in this text file.

2. Replace “ENTER YOUR PASSWORD” with your own password in the following line.

if NOT %pass%== ENETR_YOUR_PASSWORD_HERE goto FAIL

3. Save the file as a .bat (batch) file (you can name it whatever name you want)

Save as batch file

4. Now double-click on the .bat file that you have just saved. A new “Private” folder will be created.

5. Copy and paste all your private and important data to this “Private” folder.

6. Now again double-click on the batch (.bat) file. A command prompt window will ask you for confirmation. Press “y” to continue.

Lock folder private with password

7. The “Private” folder will go missing this time and you can only find the .bat file.

Private folder gone missing

If you have enabled the “Folder Options” to show the hidden files, you will an empty “Control Panel” system folder.

8. To get the folder back, double-click the .bat file again and you will be asked to enter the password that you have set in the step 2.

Enter password to open private folder

The “Private” folder re-appears again!

Private folder

You can see that the trick actually works but there’s a small catch. Anyone can open the above batch file in a text editor and can actually see the password that you had entered. Hence we’ll try to convert this batch file to an .exe (executable) file so that it can’t be opened it in text editor.

To workaround this issue, download this Batch to Exe file converter and convert the above .bat file to an .exe file. That is it!

Related Posts with Thumbnails

1 thought on “[How To] Password Protect A Folder Without Using Any Third Party Software”

  1. The code works perfectly but the files are not really hidden. When a user show the hidden folders, it is possible to see the files in the controlpanel “empty” folder… Also, if the user type in the windows search form *.* then he will be able the find everything inside that private folder.
    I’m using Win7 Pro.

Leave a Comment