Windows Hosts file: You don’t have permission to save in this location

Share this article :


You are editing the hosts (or services file) and trying to save the file. Unfortunately, you are getting permission denied error while saving the hosts (or services file).

You don’t have permission to save in this location. Contact the administrator to obtain permission.

Hosts - Save as permission error


1. Open a new notepad by right clicking on it and select Run as Administrator. *Below screenshot is the example to run a program as administrator.

Windows - Run as Administrator

2. Copy all the contents from the original hosts file (please make a copy of backup first) and paste them inside the new notepad.

3. Add the new item you required inside the new notepad. Now save the hosts file in the C:\Windows\System32\drivers\etc directory, use hosts as the filename and select Save as type to All Files. Just accept Yes to replace the old hosts file.

Hosts - Save new file


The same step was done for services file.


Related posts

Difference: Windows Size & Size On Disk
Windows Account has been Locked by Administrator
Delete Item using PowerShell Command
How to Create / Delete a Windows Service (using sc command)
© 2017 ITsiti. All Rights Reserved
Powered by KEEM