The Hosts file is more of a legacy of early IP networks and was never really designed for large-scale blocking of unwanted sites. IE-Spyad, SpywareBlaster and Peer Guardian are better alternatives for blacklisting outbound connections.
Hosts File FAQS:
http://www.mvps.org/winhelp2002/hostsfaq.htmHow to Use a Hosts File:
http://www.bleepingcomputer.com/tutorials/tutorial51.htmlhttp://castlecops.com/article-5660-nested-0-0.htmlBlocking Unwanted Sites with a Hosts File
http://www.mvps.org/winhelp2002/hosts.htmEditor's Note posted at mvps.org: In most cases a large HOSTS file (over 135 kb) tends to slow down the machine. This only occurs in W2000 and XP. Windows 98 and ME are not affected.
(scroll down the page about halfway)
LOCATION OF HOSTS FILE:
Windows XP = C:\WINDOWS\SYSTEM32\DRIVERS\ETC\hosts
Windows 2K = C:\WINNT\SYSTEM32\DRIVERS\ETC\hosts
Win 98
*Grinler = C:\WINDOWS\hostsThese files are normally located in the ETC folder:
hosts
lmhosts.sam
networks
protocol
services
To block a site with the HOSTS file, browse to its location and open in notepad.
Under "127.0.0.1 localhost" add 127.0.0.1 www.name_of_the_site_to block.com.
If you'd like to block www.hotporn.com, text would look like this:
127.0.0.1 www.hotporn.com
Example HOSTS file:
http://www.bleepingcomputer.com/misc/hosts