How To: Lock a Folder Without any software

This is a guest post by Akshay who blogs at If you like to write for TechGyo, read: TechGyo’s 100% Adsense revenue sharing program.
LockHi, in this post i m going to discuss about how to lock a folder without using any software.Locking a folder means nobody else should be able to access it. Locking a folder will enable you to protect your valuable documents and files from unauthorized access.I will use a simple registry trick to achieve the Task.

How To Lock The Folder?

Create a new folder or use any already created folder which you want to lock. I am going to lock folder akshay which is present on my desktop. To begin right click on the folder and rename it to akshay.{2559a1f2-21d7-11d4-bdaf-00c04f60b9f0} or yourfoldername .{2559a1f2-21d7-11d4-bdaf-00c04f60b9f0}.After renaming it you can see that the folder becomes locked and its icon changes.

How To Unlock The Folder?

In the previous step you locked a folder now i will teach you how to unlock the folder. To begin Open command prompt and then navigate to location where your locked folder is. My folder is placed on desktop so ill change working directory to desktop. So i will type cd Desktop to change directory to desktop. You can simply type cd /yourpath. After that type command ren akshay.{2559a1f2-21d7-11d4-bdaf-00c04f60b9f0} akshay this commands rename it back to just akshay and folder will become unlocked


  1. to unlock
    C:\Documents and Settings\Administrator\My Documents>ren foldername.{2559a1f2-21d7-11d4-bdaf-00c04f60b9f0} foldername

  2. When you lock the folder with registry key it shows a lock icon but it can be opened by anyone, any time. The folder is not locked its just the icon shows a lock but it can be opened

  3. I made a code that would lock and unlock the folder so I wouldn't have to go to CMD or renaming the folder.
    If you want the code you can just click on the link below:

  4. I have done all these stuff like rename ord delete..!! bt still it's not working...!! and also using cnd with that command..!! bt still remain same....!!!! not open
    when i'm writing the command
    it's showing a message "Access is denied" below the command.

  5. Thats strange, as you already mentioned that it was working before you reinstalled xp . it should work after it as well.. try renaming folder to anything else like just rename it to techgyo and try opening it should work

  6. hey i locked my drive floder with command prompt { E:\cacls /e /p everyone:n } . bt it's opposit command ain't working { E:\cacls /e /p everyone:f }. actually i installed again win xp that time it was running bt after installed win xp it's not wosrking...!!! PPLLLLZZZ help me.....

  7. Dear All,
    Thanks for giving this idea.

    I want to add some more points which can be useful.

    First thing is that we can use any key like keyur. {21EC2020-3AEA-1069-A2DD-08002B30309D} also.

    Second thing is that no need to use "ren" Command. Just remove that key from name it will automatically remove lock from folder.

    Hope you all like this.


  8. I really like your lock icon and would like to know where you got it and/or how I can go about getting the rights to use it on a website. I would really appreciate it. Thanks!

  9. Chandan first of all which OS are you using ?after the lock icon appears are you able to open it ?

  10. Dear Akshay,
    The folder icon seems to be locked but the folder doesn't lock!! The contents can be still accessed after locking the folder..

Comments are closed.