Blog

- Showing all posts in category: Windows
# Windows hostfile is being ignored
Published on 20-05-2016

I had to modify the hosts file on a Windows 10 machine, but the changes were ignored all the time. It took me literally 1 hour to found out why it didn' t work. The client PC was running Windows 7 before and upgraded to Windows 10. He had 2 windows folders.

Usually I navigate to this folder by typing it in the file explorer:

C:\Windows\System32\drivers\etc

The host file was indeed located here. But the changes did not affect. The problem was that there were multiple Windows directories so this one was unused.

To make sure that you will always get the proper hosts file, go to this location by using the %SystemRoot% environment variable:

%SystemRoot%\System32\drivers\etc\hosts

For more generic information about the hosts file, visit this Wikipedia article.