How To Block Websites
So you want to block your kids from going to certain websites, eh?
There is a lot of software out there that blocks websites, some of it good, some of it not so good.
There is a simple way to block websites on your home computer without installing any additional software.
To block specific websites on a windows computer, you only need to edit a single file on your system.
To block a website, say, Facebook, simply edit the hosts file so that DNS lookups for that website return 127.0.0.1. (A special IP address that resolves to your computer.)
Steps to block websites using the hosts file on Windows:
- Open the hosts file for editing. This file is found in the “C:\WINDOWS\system32\drivers\etc” directory. Browse there, and locate the file called “hosts”. Open this file for editing in Windows Notepad. Or, if you’d prefer, simply go to Start->Run and type notepad.exe c:\WINDOWS\system32\drivers\etc\hosts
- Add a line for each entry you’d like to block. For our Facebook example, the format will be “127.0.0.1 facebook.com”
- Save the file. That’s it.

Voila! Now, when you try to go to Facebook.com in any browser, be it Internet Explorer (IE), Firefox, Google Chrome, Safari, Opera — whatever — the browser will say that the website cannot be found.
Here is an example from IE7:

To unblock the website that you just blocked, simple remove the line from the hosts file.
Note: You may have to restart your browser or computer for the changes to take effect. Alternatively, you can try clearing your computer’s DNS cache by typing “ipconfig /flushdns” at the Start->Run command line.



Leave a Reply