53

How to Password Protect a Folder In Windows (2022)

Share

You may want to keep certain files or folders private. For example, you might want to keep personal information private, or access a file that others shouldn’t see. You can easily password protect a file in Windows 10.

This article explains how to password protect a file using different methods in Windows 10. Note that the features available for password protection vary by file type and version of Windows.

However, all versions of Windows have similar features for protecting files from prying eyes and unauthorized access.

1. Use Third Party Softwere GiliSoft To Protect File

Follow these steps to get started with GiliSoft:

  • Download and install the application on your computer.
  • Start the application and enter the password you set during registration.
  • Click on the “Locking file” option from the “lock disk” options on the next screen, then select the “Lock folder” button located in the right corner of your screen.
  • To lock a folder, select it and press OK. In this example, we’re locking the “Saved Pictures “folder .
  • The next screen will show that the folder is now locked.

You can unlock your folder by clicking on the ‘Unlock’ button. Once you’ve done that, the folder will appear as a normal, visible folder.

2. Lock Your Folder Without Any Third Party App

You can password-protect folders in Windows 10 using a batch script. Here’s how:

Create an empty text document within your folder by right-clicking an empty space and selecting New > Text Document.

lock folder

You can see the new text document is created on the screen. Double-click the text file to open it and paste the following text into the new document.

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%==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

Replace “Your-Password-Here” with the password you want to use to lock the folder.

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%==hackreveal@prakash-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
  • Click File
  • Select Save as
  • Enter Name as FolderLocker.bat
  • Select “All Files”
  • Click the save button

Double-click on the BAT file to create your “Locker” folder. This is the folder that will be locked with your password. You should now have a folder, as well as a file, named Locker.

To keep your sensitive files safe, follow these steps:

  1. Place all desired files into the Locker folder.
  2. Double-click on the Locker.bat file to open it.
  3. Enter Y when Cmd Open , then press Enter to lock the folder.

Your folder will now be hidden from view – but don’t worry, this is normal!

To access your hidden files again, double-click on the Locker.bat file and enter your password when prompted. Your Locker folder will reappear and you can continue using it as usual.

3. Hide Youre Files

  • To hide a file or folder: right-click on the file or folder you want to hide and select Properties. In the Properties window,
  • Check the Hidden option under Attributes. Click Apply and then OK.

Your file or folder should now be hidden. To view your folder again, click on the View tab in your Windows 10 file manager. Then, select Options > Change folder and search options.

Click on the View tab in the File Options window. Then, Select Show hidden files, folders, and drives . After that, click Apply and then OK.

Read Also:

The Top 10 Best Keylogger Apps for Android Devices

How to Hack/Bypass Android Screen Lock Without a Password

How To Download Instagram Reels Video And Stories

%d bloggers like this: