Search

Best Way To Block Any Website Without Any Software

Share

Although there are number of  softwares which may help you to block any website any where but yet the best way is to do it without any software because its free, simple and most of all you are not dependent on any software. All you have to do is to edit windows HOSTS file to block a website. After website is blocked, you wont be able to access it in any web browser even by using any software.

Tidbit : How To Block Websites In Internet Explorer And Mozilla Firefox?

The main purpose of HOSTS file is to maintain personal list of web addresses. Whenever you type want to open a website, its URL is first matched to the list in HOSTS file, if found you will be directed to that IP without first consulting a DNS [Domain Name Server]. We will use the this principle to redirect the URL you want to block to your router's adderess or any other website you want to open instead of that website.

Follow these simple steps:

  1. Open Windows->system32->drivers->etc or if your Windows is installed in C: drive simply type the following address in your address bar.
  2. C:\WINDOWS\system32\drivers\etc

    HOSTS File Location

    HOSTS File Location

  3. Double click on hosts file and select notepad from the list.
  4. Open With List

    Open With List

  5. Now your hosts file would look like the screenshot below:
  6. Default Hosts File

    Default Hosts File

  7. Suppose i want to block a website with URL www.youtube.com and the IP addess of my router is 192.168.1.1, all you have to do is to add a new line to your hosts file, write the IP address of your router followed by the website you want to block. In our case, adding the following line to HOSTS file will do the work
  8. 192.168.1.1 http://www.youtube.com
    192.168.1.1 http://youtube.com

  9. Now your hosts file would look like this:
  10. Modified Hosts File

    Modified Hosts File

  11. What we exactly did is that we redirected youtube.com to our router's configuration page. Remember you can also replace your router's IP addess with the IP address of any other website for example IP address of google.com. In that case when a person will try to open youtube.com, he will be redirected to Google.com.
  12. Router-Configuration-Page

    Router-Configuration-Page

  13. You can find Google.com IP address from using this command over your DOS
  14. ping www.google.com

  15. Save HOSTS file [Ctrl+S].
  16. Restart your system.

I have tested this procedure on my PC. I was not able to open the website i blocked on Internet Explorer, Mozilla Firefox and Google Chrome. All of these three browsers opened the configuration page of my router whenever i tried to access the blocked website.

To keep yourself updated with latest news from Microsoft, Apple, Google, Phones and Web, follow us on Follow us on TwitterTwitter, join our Follow us on FacebookFacebook fanpage or subscribe to our Subscribe to RSS FeedRSS Feed

Related Posts:

Comments on this Article

Post A Comment