Professional Pc Support

Professional Pc Support

Home

Products

Downloads

Contact us

Site map

Sends email to us!
email me!
 


Hosts file modification

This page contains instructions on how to modify the Hosts file, used in Windows to direct internet explorer to alternate addresses (addresses that are different to what the DNS service resolves). These instructions are valid for Windows 2000 and XP only.

Procedure:

Note. Make sure you know the web address and IP address of the site that you are trying to divert.

1. Launch Windows Explorer (Start, Programs, Accessories, Windows Explorer)

2. Make sure that you can view all files (Tools, Folder Options, View, then select "Show hidden files and folders", Ok)

3. Make sure that you can see file extensions (Tools, Folder Options, View, then De-select "Hide extensions for known file types", Ok)

4. In the left pane, expand the drive C: (usually appears like "Local DIsc C:"). Note: "Expand" means to click the little "+" sign next to it, so that the sub folders are listed below it.

5. Expand the "Windows" folder.
    Expand the "System32" folder.
    Expand the "Drivers" folder.
    Left click on the "Etc" folder.

6. You should see a file called "Hosts" in the right pane. Note: It is the one that is just "Hosts", not hosts.sam, or lmhosts, or any other derrivative.

7. Right-click on the Hosts file, and choose "Open With..." from the menu. Note: If that option is not available, then select "Open".

8. Select "Notepad" as the program to use to open it, and click Ok. Note: It may say that it does not know what program to use, and offer a choice of using the web, or selecting a program to use. You must "select a program to use" and choose "Notepad".

9. You will now be in notepad, and the contents of the Hosts file will be displayed. Any lines beginning with a hash symbol ("#") are remark lines that are ignored by Windows. You will see a line similar to...

      127.0.0.1        Localhost

This line must remain, and all new entries must appear in the same format below this line. So for example, you may add a line such as...

      192.168.0.1      www.mydomain.com.au

to direct that web site to an alternate address. When finished editing the file, just close Notepad, and make sure you say "Yes" when prompted to save the file. Your done!
 

These pages were last updated on 25 Nov 2004.