UPDATE : You can easily take and restore ownership of registry keys using RegOwnershipEx.
Sometimes it becomes very necessary for a Windows user to take the ownership of a file in order to complete the work. Suppose you want to edit the default text for Charms Bar ( + C).
All the settings of Charms Bar default text are stored in a file named twinui.dll.mui, which is placed under System32 folder of Windows drive.
Moving on, if you’ve finished tweaking this file with your customized strings using third party tool like Resource Hacker, then you need to replace the tweaked file with default one, to get the desired results. In that case, you have to take some special permissions from Windows to do that.
Page Contents
How To : Take Ownership For File, Folder, Drive, Registry Key
This phenomenon is called as “taking ownership”. By default Windows sets ownership and full permission control to TrustedInstaller. Now lets see how to take and restore ownership from this TrustedInstaller…
Using Elevated Command Prompt
1. Open Command Prompt with administrative privileges.
2. Use following commands to take ownership:
For taking ownership of file for currently logged user : takeown /F “full path of file”
For taking ownership of file for group of administrator : takeown /F “full path of file” /A
For taking ownership of folder/drive for currently logged user : takeown /F “full path of folder/drive“ /R
For taking ownership of folder/drive for group of administrator : takeown /F “full path of folder/drive“ /A /R
By Adding “Take Ownership” To Right Context Menu
This is the simplest and safest bet to play for taking ownership. It will save you time and extra work. Just download them and run, that’s it.
To add the “Take Ownership”, download following registry and run it:
To remove “Take Ownership” from context menu, run following registry:
Taking Ownership Manually
If you are looking for taking ownership of a file or folder or drive manually, then here is the working way. Follow each step carefully.
1. Right click on target object whose ownership you want to take. Pick Properties. Switch to Security tab.
1.1 If you are looking for taking ownership of any registry key in Registry Editor, right click on that key and select Permissions. Now proceed as directed in next steps.
2. Obviously the default owner is TrustedInstaller. Click on Change in below window.
3. Then click Advanced in Select User or Group window.
4. Previous step yields below shown window, click Find Now.
5. Now we have the search results here, pick your user name, click OK.
6. Then click OK in Select User or Group window as well.
7. Thus you have successfully changed the owner.
As you can see in above image, there is option for Replace owner on subcontainers and objects. If you uncheck it, you’ll get:
If you check this option, you and the correct owner who just has taken ownership will be able to grant access permission for that object. Press Yes, that’s it.
How To : Restore Ownership For File, Folder, Drive, Registry Key
To remove yourself as owner of object and give its control to default owner, you need to restore ownership which you have taken earlier using any of above illustrated method. Use following registries to restore ownership.
You can add “Restore Ownership” to right click context menu by running following registry:
You can remove “Restore Ownership” to right click context menu by running following registry:
P.S. : Never bother to take ownership of Windows drive (C: Drive usually), it yields unstable OS and may result in serious causes to your installation.
Hope you find the article helpful!
27 Comments
Add your comment
gud article… thanks 4 share
hi kapil, i can’t take the ownership of a f: drive of my computer
takeown /F “F:“ /R
Plz. help
^^ Hi ODIO,
You’re almost there, type takeown /F “F:“ /R instead of takeown /F “F:“ /R.
thanks bro ,. is there any way to set all the permissions to default owner for whole windows?
How Can I Remove Windows.old folder after refresh?????
Thnkxxx…
@ Olivia Mayers, use this command:
RD /S /Q %SystemDrive%windows.old
Thanks Kapil for gr8 guide.
Thanks!!
Works 100%
hi,kapil sir my problem is in c-drive.but to take ownership of c-drive is risk.so what to do.in my registry editor its showing its showing c-drive in front of load.
Sorry, but “takeown /F “full path of file”” is not running. I get back the answer “access denied”. Please help.
^^ Make sure you’re the administrator of system and running administrative Command Prompt.
hii there, how to remove the take ownership ?
^^ Merge this registry: http://get.kapilarya.com/Remove-Take-Ownership.reg
takedown is not recognized as internal or external command
Help! Need to restore TrustedInstaller as owner of C: Drive
this is from SMCBEAN i also did the same PLS HELP i everyone:
So I did something stupid without doing enough research on the topic. I just upgraded to windows 10 and tried to delete a folder in programs on my C: drive. Long story short I was denied access and misinterpreted another article that I read and ended up changing my C: drive owner from TrustedInstaller to myself and that included all folders and subfolders and files. I realised my mistake too late, now I’m freaking out because, another article says, under no circumstances should you change the owner of the C: drive. Also it is still denying me access to delete that same specific folder (folder is irrelevant, nothing important) in programs. Now I don’t know what to do or how to change the owner back as I don’t know what TrustedInstaller was in charge of. Could someone please help me if possible? Thank you.
^^ Unfortunately, it’s not possible to restore ownership to TrustedInstaller for each file/folder on your system root drive. I suggest you to take backup of your data and make clean install: http://www.kapilarya.com/how-to-make-clean-install-of-windows-10
I and in running Windows on a Citrix Xendesktop vdisk. I created a version R/W on the disk. I logged in locally as the local admin. Opened a command prompt in admin mode. Launched Regedit from there but it still won’t let me add Full control to local admins or create the local admin and give it full control. The client that I am working with blocked any downloads so you Permissions Util won’t work either. Any ideas?
I am running Windows 10 on a Citrix Xendesktop VDI. I created a version essentially a snapshot of the vdisk. I logged in locally as the local administrator account. Opened a command prompt in admin mode. Launched RegEdit from there but it still won’t let me add Full control to the reg key for local admins or create the local admin and give it full control. Any ideas?
^^ Since this is case of registry keys, you may use RegOwnerShipEx tool: http://www.kapilarya.com/regownershipex-handy-freeware-for-taking-ownership-of-registry-keys
Hi,I am Akash and I am searching for the. Solution for error in windows 10 while setting up my profile pic……I am a subscriber in ur you tube channel ,so can u upload a video to solve my problem in same topic plzzz……..
I have two accounts, one is the administrator, the other is local. I always use the local not admin but can save files and things like that and i forgot what my administrators password was, i deleted its account, then i remember the password abotu a week, then i typed it and there was this ‘device is offline something something’ i dont know what to do!! I think it did that when i deleted the account, maybe.
It says that there was error and that access was denied.
I have limited command prompt but basic skills. I have Windows 10 and was told to use your files here to alleviate an issue i have. I get errors using your command prompt when i cut and past either in cmd by admin or cmd shell by admin. The manual method does not work. Any suggestions?
the Ngc folder was empty, what should ido?
Thank you.
^^ 👍
yaah finally its 100000% working thanks