How-To Geek
How to Deny Access to Files or Folders in Windows Vista
This is a guest post by Abhishek Bhatnagar from www.technixupdate.com, a blog covering Computer tips and tricks.
Most of us use our computers in a shared in environment with our family members, friends etc. But sometimes we may want set some permissions so that we can actually restrict access to certain folders which do not lie in our My Documents, My Pictures etc.
In this case when you can restrict access to a particular folder which could be any where on your hard drive.
Set File or Folder Security
Right click on the folder which you want to block from other users and select Properties.
Now click the Security tab in the folder properties window, and then click the Edit button.
Click on the Add button to open the “Select Users or Group” window.
Now you can enter the username of the account for which you want restrict access in the text box (Use the “Check Names” button to validate)
or
if you are not sure about the username then click the Advanced button, which opens the search window.
To search all users click the Find Now button and then locate the user which you want restrict access to the folder and click OK. Now, you will see the username listed in the Security Permissions window, click on the username to select.
Select the Deny Permissions for that user by checking the Deny box for Full Control.
Now, you will be shown a Windows Security message which in short says that Deny entries always override the allow permissions. Click Yes, and then click OK.
In this way you have restricted access to the folder for a particular user (in my example it was a guest user account in Vista).
Tip: You can also restrict access to all the users in vista type Everyone as the username, but this will also include your account as it is also a part of Everyone user group.
Subscribe to More Computer Tips and Tricks like this from TechnixUpdate
Editor’s note: The files and folders within your user directory should already be off-limits to other regular users on your computer. Of course, if the other users are administrators, they can always reset any of these permissions, including deny. The main reason to use this technique would be if you are trying to remove access to folders on another drive, for instance hiding sensitive documents from children, etc. Just make sure those user accounts don’t have administrator access.
Got Feedback? Join the discussion at discuss.howtogeek.com
Comments (27)
Programmer by day, geek by night, The Geek, also known as Lowell Heddings, spends all his free time bringing you fresh geekery on a daily basis. You can follow him on Google+ if you'd like.
- Published 07/10/08


![folder-properties[3]](http://cdn.howtogeek.com/public/images/blank.gif)



Thanks for publishing it.
Nice post!
I definitely appreciate the contributed article… file permissions is something that I have not covered, but really should do more on.
In Windows XP and above:
To see the Security tab on the Properties window, you have to have the Simple File Sharing turned OFF… In any windows explorer window: tools -> folder options -> view -> Simple File Sharing
In Vista:
Press and release Alt key in windows explorer to see the menu
In any windows Home edition:
There is no way (tell me I’m wrong) to display Security tab. Use native command cacls (Change ACLs) or xcacls instead.
I recommend to use powerful utility http://setacl.sourceforge.net/ to set the permissions (ACEs). Also sets ACL inheritance behavior. Able to set ACLs not just for files. (registry entries, services…) Advanced knowledge required.
thanks for finally being one of the few who actually help with vista. all the other forums who bash it have lost any credibility they probably never had to start with.
@0zSpitt
Thanks… our goal here is to be helpful whenever possible. You can also leave any help questions over on our forum, where we’ve got lots of people that answer questions.
http://www.howtogeek.com/forum/
Great post Abhishek…Never thought of this as my computer is not usually shared.
thanks, i was just looking for this. good way to keep my por . . . pictures from prying eyes.
Thanks was trying to figure out how to do this a while ago
Finally a website that clearly explains this issue! Thanks, guys! Now I won’t have to be afraid anymore of guest account users viewing my gf’s (semi-)nude pics. ;-)
Hi,
This post was really helpful. But can u suggest any way by which we can restrict other Standard Users of Vista Machine to Rename, Write-in a new file, and Delete a folder and all this.
Regards,
Raj Kumar Arora
Er_RajArora@yahoo.com
In my last post the requirement is for steps that can do the whole task in once for whole drive/hard disk.
Hi,
I managed to remove all users from the list of permission and now am not able to access it myself. Can someone please tell me how to revoke the changes or regain access?
@Bijoy: To regain access go to Security, Advanced, Ownership and click Take Ownership to become the owner of the folder.
Niiiiice… Thanks Much!.. I was having this problem but because I have a partition. Did not have it when I had just one drive =)
Setting NTFS permissions can indeed be very useful. But be very sure you know what you are doing before doing this on an important file or folder. NTFS permissions is a complex topic and there are many implications that are far from obvious. Don’t even think about changing permissions on any system file or folder.
Larry Miller
Microsoft MCSA
That is just the problem, when you hit the so called “find all users” button it simply does not find all users in the network. This has been an ongoing problem with Windows 7 also. There is no way that all users in the network show up on that list, therefore it’s impossible to not share with them. It’s either Everyone or Nobody.
Thank you so much for posting this, I have been racking my brain trying to figure it out without screwing somthing up. This has helped soooo much. Thanks again.
now i denied access to my folder and now can’t find it. i denied EVERYBODY and ADMINISTRATORS (stupid, i know) but i need it. it’s got school documents in there!! can i ever get it back?
Windows security is pretty lame. Sure you can deny other users access to some folders and files, but what if there are more than 1 admins on that computer. The security in this case counts for nothing, any admin having access to absolutely everything.
Hi Frenz,
I was trying to take the ownership of the denied folder,however, when I rite click on the properties of the folder it does not show me security tab on the window that opens up. If securtiy tab is not there, how can I access the folder and take the ownership.
Can someone please help me
@Abhinav
First of all security tab will only show up in drives formatted with NTFS. If the drive is ntfs formatted, then go to explorer->Tools->Folder Options . In the view tab, go all the way down and uncheck “use simple file sharing”. Apply OK . Now you can see the security tab .
this helps me a lot from unauthorized access from the guest account … thank you so much
i know this works but i know theres another way to stop someone from opening a file at all and i know it was used in windows 95,98 and xp b ut i cant find it in windows 7 i know the some what know the name of it like edit it was called in windows xp where you can stop anyone who would just pop on to your computer and try to access your hard drive it was a built in program that came with windows and it has nothing to to do with typing a password to get in it cause you cant use a password it just simply no access at all and i hope you can help me with that so i can stop someone from accessing my harddrive
Thank you, this really helped. When I tried other websites for help, they all wanted me to pay a “fee” first! Thanks so much. Angela Arvada CO.
How I do it if the folder is on a network drive?
Thank you !