There seems to be a lot of half formed and incorrect explanations of how to properly set up permissions to prevent the deletion of a folder and all of its contents. Which is exactly what I am trying to do, so my question is: How can I prevent the deletion of a folder and all of its contents, in windows 10.

Some Background Research: Here is an answer that claims that setting both the folder and its contents to deny delete will solve the problem - Verified not Working
Here is another answer that claims that to prevent the deletion of files you must deny write on the parent folder - Verified not Working

Now, I could try removing all other permissions. I could change Administrator and my user account and restrict them to simply reading and executing. But then, I am worried about how I would ever be able to change the file permissions after that. As theoretically that should "brick" the files and make changing their permissions impossible.


Right Click > Properties > Security > Advanced > Add > Deny - Everyone (Delete and Delete subfolders and files)

This will prevent the folder and all of its contents from being deleted, even if you try to initiate a delete further up the folder hierarchy. And any files created or moved to the folder will automatically be granted these same permissions.

Delete by itself, does not really work in any logical and explainable way. It seems to be able to be overruled by other permissions. As it is possible to get the same result as both of them with just delete if you massively trim back the permissions you allow other users and change the ownership of the main folder.

| improve this answer | |
  • This won't prevent the file being zero-filled, however. – T. Sar Apr 26 '17 at 11:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.