How to block Websites Using DNS or Host File

Want to block websites so that any of the user won’t be able to access them? By following this straightforward and free method you can filter websites in both PC and Mac without using any Software.

Block websites using OpenDNS

In this method we are going to use OpenDNS to block users from accessing certain websites.OpenDNS is a pure DNS company which gives you free content filtering for home use. To block certain websites in your network all you have to do is sign up a free account and point the DNS server on your router to OpenDNS server. After that you can use your OpenDns account to block those unwanted websites. To use the service of OpenDNS you have to add the IP address of their DNS server as your Primary DNS.

How to block Websites Using DNS or Host File

Visit OpenDNS

Block websites using Windows host file

  • Navigate to C:\Windows\System32\drivers\etc. If Windows is not installed in C drive substitute the appropriate drive letter.
  • Double click on Host file. Select Notepad when Windows prompts you to choose a program.
  • Type the addresS of the website you wish to block, each prefaced with 127.0.0.1 and a space.
How to block Websites Using DNS or Host File
  • Click File>Save to save your changes. Dismiss any warning that you might receive because of editing of your host file.
  • Open a browser to test your edits in host file. You will notice that any of the blocked websites will not display in any browser or open in any browser.

Found this post Useful follow us on Facebook or Twitter to get more updates