Secure your folder with password without using any additional software in your Windows 7/8.1/10 PC/laptop
This article will be helpful for those who want a better level of privacy than the level offered by basic OS functionalities. And also do not want to struggle with various software available as free or paid.
In this article we will teach you to password protect a folder(and transfer your private stuff in it) just by using command prompt.
Okay, first of all you need a text editor(notepad will do), and you have to copy the following code there. Replace “YourPassword” with the password you want to give to the folder (without double quotes).
title Folder Private
if EXIST TWlock goto UNLOCK
if NOT EXIST Private goto MDLOCKER
echo Are you sure you want to lock the folder(Y/N)
if %cho%==Y goto LOCK
if %cho%==y goto LOCK
if %cho%==n goto END
if %cho%==N goto END
echo Invalid choice.
ren Private TWlock
attrib +h +s TWlock
echo Folder locked
echo Enter password to unlock folder
if %pass%==YourPassword goto Decrypt
attrib -h -s TWlock
ren TWlock Private
echo Folder Unlocked successfully
echo Invalid password
echo Private created successfully
Now save the file as a .bat file(give any name you want, I have given name “Cipher”).
Third step is to open this file. ( I recommend that you open this batch file by command prompt rather than by clicking on it, in this way you will be able to see all the action)
As you open the file for the first time, it creates a folder named “Private” in the same directory as of the batch file.
You can place your desired stuff in this folder.
Now again open Cipher.bat in cmd and you will be presented with a choice of yes or no. Once you type ‘Y’ the folder will be locked.
After this the folder will be locked.
Whenever you need access,open Cipher.bat again, Enter the required password and the folder will be unlocked.
This is it! You are ready to go. And if you face any problem or have any doubt, comment below and we will resolve asap.