Windows XP hosts file

To compliment this site and all the online computer tutorials on offer I have setup a computer help forum where you can go to ask your questions.

How To Block A Webpage

Why would I want to block a specific web address?
Maybe you have noticed your child visiting the same site time and time again after you have given clear instruction for them not to go there.
If this is the case follow the instructions below.

Is there any way to block specific web pages in Windows XP?
You can block specific web pages in windows xp but only the home page of that site so let’s say you wanted to block a site called www.foulmouth.com (which is a real life site, not the kind you would want your children to visit and probably not one for most adults)
This site has several links to other pages on it. So even though we can type in there (home page) web address
to have it blocked. We can not stop our children stumbling upon another page in there site without specifically blocking that (page) web address also.
So it really is not a fool proof way of doing things but it certainly does help. I will now show you below how to
go about blocking a web address in Windows XP by example. Follow these steps.

1, You need to be logged on as an Administrator, or at least with Administrator rights. If you do not know how to do this click here

2, Left click with your mouse on start which is on the bottom left corner of the (screen)

3, Left click on My Computer this will open up a new window, you will see a picture of a square disk which will probably say Local Disk (C) you; need to double left click with your mouse. The window will now change to show you the contents of your Local Disk.

4, You will see lots of different named folders, these folders will be yellow in colour. You need to double left click on the one that says WINDOWS.
This will change the contents of the window once again.

 

5, You need to double left click on the folder which says system32 now look for the folder which says drivers and double left click on it. Once again you will notice the contents of that window have changed. Look for a folder called etc and double left click on it. You will now see a window with half a dozen files in it. One of those files will be called hosts if you double left click on this file it is possible that you will be presented with a box asking you what program you want to use to open it. scroll down and left click on Notepad. Then left click on the OK button.

 

6, You will now see in front of you the hosts file contents which will look very similar to this.

# Copyright (c) 1993-1999 Microsoft Corp. # # This is a sample HOSTS file used by Microsoft TCP/IP for Windows. # # This file contains the mappings of IP addresses to host names. Each # entry should be kept on an individual line. The IP address should # be placed in the first column followed by the corresponding host name. # The IP address and the host name should be separated by at least one # space. # # Additionally, comments (such as these) may be inserted on individual # lines or following the machine name denoted by a '#' symbol. # # For example: # # 102.54.94.97 rhino.acme.com # source server # 38.25.63.10 x.acme.com # x client host # 127.0.0.1 localhost

 

Now going back to our original example of blocking a website called www.foulmouth.com we would make out file look like this
# Copyright (c) 1993-1999 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each # entry should be kept on an individual line. The IP address should # be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one # space.
#
# Additionally, comments (such as these) may be inserted on individual # lines or following the machine name denoted by a '#' symbol.
#
# For example: #
# 102.54.94.97 rhino.acme.com # source server
# 38.25.63.10 x.acme.com # x client host
# 127.0.0.1 localhost
#127.0.0.1 www.foulmouth.com

So you can now see how we edit the host file to add a specific website address.
You now need to save your file.
Click on File at the top left corner of the hosts file window, scroll down to Save and left click with your mouse.
Now close any open windows which you may have opened.
Start your web browser and test your setting by entering the site www.foulmouth.com in to your browser and clicking on enter.
You should get an error message which says unable to connect.
SUCCESS :) SUCCESS:)

Ooopps it did not work what can I do ?
Ok you probably did not have the correct permissions to change the file or the file was marked read only. Follow these steps.

 

1,In step 5 once you have opened the folder called etc, right click on the file called hosts, and left click on properties.

 

2, Uncheck the box which says read only, and click Apply. Now click OK to close the window.

 

3, You have just given yourself write permissions to edit the hosts file. It is probably best if you change these permissions back to read only when you have finished.

If the tutorial above is to much for you for what ever reason you can use some third party software caLled K9 which can be found here.

K9 can be downloaded free of charge it has a very simple interface and gives you fantastic parental control over what can and can not be done on the interenet.