Block a Site
1) In the Windows start menu search box type "notepad" (without the quotes) right click the entry and select "Run as Administrator" then enter your user credentials for the UAC prompt and click yes to open notepad. In notepad at "File" select "Open" then browse to C:\Windows\System32\ drivers \etc in the window that opens select " All Files" then "hosts" then click "Open" to open the default Windows Hosts File location.
2) The #1 snip below is the default Windows 7 Hosts File that opens, as you can see with the use of this ( # ) symbol, Windows does not "read" any of the default information in the file, so it's up to you whether to delete it all or not but it may be useful to leave it there for future reference.![]()
![]()
![]()
![]()
![]()
3) If I wanted to block access to ebay.com, the first entry in the file would need to be 127.0.0.1 localhost on its own line, on the next line I would add 127.0.0.1 ebay.com with at least 1 space between the IP address and the host name; then back at "File" select "Save" then "Exit" to close notepad.![]()
From:http://www.sevenforums.com/tutorials/78266-hosts-file-use-windows-7-vista.html?ltr=H