You can block particular websites from your computer. Are you worried about your kids excessing objectionable websites behind your back or spending too much time on social networking websites? Although your kids may be geekier than you are and some kids simply cannot be stopped from unblocking and accessing certain websites, if you are able to block websites it can act as a deterrence to a great extent.
Benefits of blocking certain websites from your computer
The Internet is a great resource but it can also be a great distraction. When you think your kid is studying all night (they actually used to do that you know?) he or she might be chatting with friends or visiting porn websites or spending a big chunk of their valuable time (the time they can use studying or getting some sleep) on Facebook.
You can block websites even if you cannot resist from using them.
Effectively blocking websites
In order to effectively block objectionable and nagging websites first of all you need to take charge of your computer. Only you or another responsible person should have the admin access to the computer so that if a website is blocked, only someone with an admin access should be able to unblock it. You can restrict access both on Windows and Ubuntu.
Once this aspect is taken care of let’s see how to block particular/objectionable websites on your PC.
Blocking websites in Ubuntu
If you are using Ubuntu you are in much control anyway. Every system level change requires you to enter a password so once you have blocked websites on your Ubuntu PC, only the one knowing the admin password can unblock them.
Open the Terminal Window (Applications -> Accessories -> Terminal). Type
sudo gedit /etc/hosts
and press Enter. You’ll be asked to enter your admin password. The file will be opened in gEdit.
Above the line “# The following lines are desirable for IPv6 capable hosts” you can enter the websites you want to block like this:
127.0.0.1 website1.com
127.0.0.1 website2.com
127.0.0.1 website3.com
and this way you can block all the websites you dislike. Subdomains need to be blocked separately:
127.0.0.1 bad.website1.com
127.0.0.1 website2.com/bad
Save the file and close it. These files are blocked on your Ubuntu PC. I haven’t checked on the older version but on the latest version of Ubuntu 10.04 you don’t need to restart your computer.
Whenever somebody tries to access these websites he or she will encounter the “server not found error”.
Blocking websites in Windows XP
In Windows XP too it’s pretty much the same process. You’ll enter the same sort of information, just the name of the file and its path differs in Windows XP’s case. You need to open the following file:
C:WINDOWSsystem32driversetchosts
It can be C: or whatever drive you have installed Windows XP on. You can use notepad.exe to open this file. It may contain some incomprehensible data. Don’t touch it. Just go to the last line enter the information given above, that is,
127.0.0.1 website1.com
127.0.0.1 website2.com
127.0.0.1 website3.com
127.0.0.1 bad.website1.com
127.0.0.1 website2.com/bad
Save the file. If you can still access the websites, you need to restart your system.
From Windows Vista onwards you need to have admin permissions in order to be able to fiddle with this file.




