TechBooky AI Assistant
TechBooky AI Assistant
👋 Welcome to TechBooky AI Assistant

I can help with:
🔎 Tech News
🤖 AI Topics
💻 Gadgets
☁️ Cloud
✍️ Guest Posts
📢 Advertising
🔗 Backlinks
📩 Newsletter
  • AI Search
  • Cryptocurrency
  • Earnings
  • Enterprise
  • About TechBooky
  • Submit Article
  • Advertise With TechBooky
  • Contact Us
TechBooky
  • African
  • AI
  • Metaverse
  • Gadgets
  • Intelligence
  • AI Search
Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors
Search in posts
Search in pages
  • African
  • AI
  • Metaverse
  • Gadgets
  • Intelligence
  • AI Search
Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors
Search in posts
Search in pages
TechBooky
Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors
Search in posts
Search in pages
Home Tips

Tip: Here’s How To Lock Folder In Windows 10

Contributor by Contributor
May 14, 2020
in Tips
Share on FacebookShare on Twitter
Share this story

Send it to someone who should read it.

f Facebook X X in LinkedIn wa WhatsApp tg Telegram @ Email
In Brief
  • Whether you’re a desktop user or a laptop user, there is no doubt about the fact that almost every individual wants to keep something private.
  • Whatever it is your financial details, some important office docs, or any other personal file that you don’t want to share, we all deserve some privacy.
  • So, let’s delve into how to lock folder/files in Windows 10 so that we can keep them away from prying eyes.

Whether you’re a desktop user or a laptop user, there is no doubt about the fact that almost every individual wants to keep something private. Whatever it is your financial details, some important office docs, or any other personal file that you don’t want to share, we all deserve some privacy. So, let’s delve into how to lock folder/files in Windows 10 so that we can keep them away from prying eyes.

Locking a folder doesn’t require you to learn a lot of stuff. All you need to learn are some basic tips and tricks and you can easily lock any folder in Windows 10. You can create a secret folder that will stay password protected and only you will be able to open it. That folder is going to be your secret Pandora’s box. Sounds fun, doesn’t it? Let us get on with the steps now.

Steps to Lock Folder in Windows 10 – How to Password Protect a Folder

  1. The first step is to the right-click within the folder where the files are located. Those files are something that you want to lock or hide.

  1. The next step is to click on “New” present in the contextual menu. Then you need to click on the “Text Document”.

  1. Then hit on Enter. It doesn’t really matter what is the name of the file, you can delete it if you want later on once you have created the lockable folder.

  1. After that, double click on the text file and open it. Now, you have to copy and paste the following text to your 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

Also worth reading
Too Much Gemini? Here’s How To Dial Back Gemini In Your Google Workspace Apps How One Engineer Built a Local AI News Roundup With Docker & Qwen Count Down To The End Of Windows 10 Microsoft Support How to Resolve Webcam Not Working in Windows 7 M365 Apps on Windows 10 to Receive Security Updates Through 2028 7 Hidden Windows 11 Settings to Supercharge Speed & Privacy

: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”

  1. In the next step, you have to find where it says “Your-Password-Here” within the document. Once you have found that out, you need to replace “Your-Password-Here” with the particular password with which you want to lock the folder.                                                                                                                                                                                                                 
  2. Now, you need to click on “File” and then “Save As”.

  1. A window will open and you have to select the “Text Documents” menu bar which is located next to “save as type:”.

  1. Here, you have to select “All files” and need to change the File name into “bat”. Next, you have to click on “Save”. This creates a Windows Batch File.                                                                                                                                                                                                                                                                                                               
  2. Once that is done, you have to double click on the FolderLocker

  1. A new “Locker” folder is now generated! Now you can fill the Locker folder with anything and everything that you want to keep hidden.

  1. Now you can fill this new “Locker” folder with all the files and documents that you want to protect.

  1. Now is the time that we actually lock this folder. Open the FolderLocker file batch file that we created earlier.             
  2. A DOS screen will come up. Here you have to type “Y” on the screen and then click on Enter.                                             
  3. Amazingly, the Folder Locker window will disappear along with the “Locker” folder with all its contents as well. That’s it, your secrets are safe.
  4. Now, to unlock the folder, you need to double click on the FolderLocker batch file and then open it.                               
  5. Enter the password that you set earlier and then hit enter. That’s it, your Pandora’s box is back again.
  6. You can now open the hidden files and then lock them up again. Then you have to repeat steps 11, 12, 13 to lock back the folder again.

 

Conclusion

All that being said and done, let us share a final note with you. While starting with the Folder Locker feature of Windows 10, it is better to start with such a file that you can afford to lose. Just in case the method doesn’t work out for you or in case you miss out a step. Thus, to be safe it is better to use an unimportant file. Also, you can keep a backup of the file that you want to lock.

 

Author Name: Ajit Yadav
Email: windowsclassroom@gmail.com

Related Reading

More contextual TechBooky stories selected from tags, categories and article context.

  • File-Explorer-dark-mode-dialogs-for-Delete-Folder-1
    KB5070311 Update Resolves File Explorer and Search Bugs
  • 1604217-microsoft
    Windows 11 Gets Faster, Cleaner File Explorer in New Update
  • get-latest-updates-toggle
    Ads Could Be Coming To Windows 11 Shortly
  • Screenshot 2023-01-30 at 14.03.31
    Microsoft to Discontinue Remote Desktop Service
  • How-to-Share-Files-from-Google-Drive
    Google Drive Adds Privacy Screen for Android
  • word doc save
    Microsoft Word Now Saves New Doc Automatically To Cloud
  • OST4
    Best Ways to Open and Read Outlook OST Files without Outlook
  • GoogleDrive_Bild_BigTunaOnline_Shutterstockcom_shutterstock_1040593225_700
    Google Drive Android Gets New Video Player & Upload Features
Keep Reading Smarter

Search TechBooky with AI

Use TechBooky's AI Search to explore the context behind this story and related coverage across the site.

Try AI Search
More On This Topic
Tips
Follow TechBooky

Follow TechBooky for more technology stories and newsroom updates.

f Facebook X X in LinkedIn ig Instagram wa WhatsApp

Tags: folderhow totipswindows 10windows 10 folder lock
Contributor

Contributor

Posts by contributors. You can send in a post to be reviewed and published to info@techbooky.com

Search TechBooky
Open TechBooky AI Search Try the AI Assistant

BROWSE BY CATEGORIES

Receive top tech news directly in your inbox

subscription from
Loading

Freshly Squeezed

  • Former GitHub CEO Launches Entire to Rethink AI Code Review October 27, 2026
  • Apple Unveils M6 MacBook Pro With Wi-Fi 7 From $1,999 October 27, 2026
  • Apple Launches M6 iMac From $1,499 With Faster AI and Wi-Fi 7 October 27, 2026
  • SAP Expands Joule Tools to Build and Govern Enterprise AI Agents October 27, 2026
  • Madica Gets Another $6M to Back Overlooked African Startups October 27, 2026
  • Anthropic’s November IPO Could Raise $100B at $1.5T-$2T Valuation, Report Says October 27, 2026
  • OpenAI Says Its AI Disproved a Major Computing Hypothesis October 27, 2026
  • South Africa Fines FNB R1 Million Over Customer Data Failures October 27, 2026
  • DPI Closes $112M Nclude Fund, 93% From African Investors October 27, 2026
  • Dangote Refinery Is First to Deploy Honeywell Industrial AI October 27, 2026
  • Microsoft Voluntary Exit Offer Could Reach 60,000 Staff October 27, 2026
  • Anthropic Publicly Files for IPO as Claude Costs Face Scrutiny October 26, 2026

Browse Archives

October 2026
M T W T F S S
 1234
567891011
12131415161718
19202122232425
262728293031  
« Sep    

Quick Links

  • About TechBooky
  • Advertise With TechBooky
  • Contact us
  • Submit Article
  • Privacy Policy
Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors
Search in posts
Search in pages
  • African
  • Artificial Intelligence
  • Gadgets
  • Metaverse
  • Tips
  • AI Search
  • Intelligence
  • About TechBooky
  • Advertise With TechBooky
  • Submit Article
  • Contact us

© 2025 Designed By TechBooky Elite

Discover more from TechBooky

Subscribe now to keep reading and get access to the full archive.

Continue reading

We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.