HostOnNet Blog

Easy way to block sites on LAN

If you need to give limited access to users on LAN, you can use free proxy software from

This is a great software, you can have good control on your network and see who is accessing which web site.

There is a simple way to disable access to a web site on all users on the LAN. This is done by editing hosts file on the main PC that connect to internet, normally one with IP

On Windows


On Linux


Add following

Once this is done, no one on the network will be able to access

Repeat the same for all sites you need to block.

yahoo is just an example, don’t block yahoo 🙂

Posted in Web. Bookmark the permalink.

  • allan

    need help. need to block some sites at the office.
    we really don’t have a main computer. all are just connected to the router LAN.
    need to know easy way to block & unblock sites.

  • sanjeev

    how can I block perticular site on lan connected through main modem and router.
    we donot have any main server or pc through which internet is shared.
    internet is accessed through default geteway on main modem.

  • admin

    Some modems have a blocking option. If not, you need to block by editing hosts file on each computer on your network. I don’t know if there any other easy solution available.