16 November 2022

How To Create A Password Protected Folder In Windows Without Any Software.

By Rahul Garg

I am not sure about you but many times i need to hide some my personal stuff like pics, videos and much more. Today everyone knows about Windows hidden feature which is used to hide files so that is not too secured. Anyone can access your files by a single click on “show hidden files”. So nothing is secured today.

Today’s post is all about how to create a password protected folder in windows and hide from others. No one can access the folder without password which you have created. There is a huge list of software which can do this task but i am a type of man that don’t feel better while using software for basic purpose. Soi found a way for us….

soletz start now and follow below steps

Step : 1 – Change Windows Settings

  • You have to change some basic settings of your machine to create that password protected folder.
  • go to control panel > folder options > view
  • now mark on show hidden files, folders, and drives

Step : 2 – Create the password protected folder

  • Just paste below code in notepad.

cls

@ECHO OFF

title Folder Private

if EXIST “Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}” 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 “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 passwordgoto FAIL

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

ren “Control Panel.{21EC2020-3AEA-1069-A2DD-08002B30309D}” Private

echo Folder Unlocked successfully

goto End

:FAIL

echo Invalid password

goto end

:MDLOCKER

md Private

echo Private created successfully

goto End

:End

  • type password of your choice at the letters your password in above code
  • and save that as “private.bat”
  • Now once click on file private.bat and it will create a new folder named as private.

Step : -3 Lock the folder

  • click on private.bat and it will ask you to lock your folder
  • type y for yes and n for no
  • now your folder is locked

Step: -4 Open the folder

  • again click on private.bat and now it will ask you to enter your password
  • type the password and click enter
  • your folder is unlocked now
Please follow and like us:
Pin Share