How do you edit hosts file on Windows 7
I'm trying to edit the hosts file (C:\Windows\System32\drivers\etc\hosts
), because I want to setup a local redirect for my website (like I've always done in XP). However, I can't save the changes!
I have taken ownership, I have allowed my account full access and have tweaked every other setting I can think of. Every time I edit and save it, "Access is denied" pops up.
How do I get past this?
Solution 1:
You have to open it with administrative access.
Launch Notepad with Administrative access then re-open the file.
Solution 2:
run notepad as administrator by right-clicking on a shortcut to notepad, and then opening the hosts file.