HOW TO MANUALLY BLOCK A WEBSITE FROM YOUR PC

Some of us don’t want our kids watching adult movies and some don’t want their kids clicking their blog ad to prevent ban. Most people have other reasons of blocking some certain sites from showing in their pc.

So on today, we are going to know how to block sites from our pc manually without stress. Note that if you block any site it can’t be opened by any browser except you reverse it and remember that this tutorial is very simple to comprehend.

For this trick to work we are going to edit the host file of our windows and we will use the Ip address “127.0.0.1 (i.e localhost)”.Whenever somebody tries to open the blocked website the user will be redirected to localhost.

1. If you’re running vista or windows 7, open your notepad as admin

2. Now click “file” and press “open” then go to C: \Windows\System32\Drivers\Etc and locate the file “hosts”.

3. When this hosts file is opened in Notepad, at the end of the file you will see something like “127.0.0.1 localhost”.

4. Under “127.0.0.1localhost” just add another website URL that you want to block. Example 127.0.0.1localhost 127.0.0.2 www.amazon.com 127.0.0.3 www.facebook.com

Now try to visit the site you just added with your browser and watch what happens.

Tip: Remember that you can always disable it by deleting the site you input.

You can drop your comment at the comment box below. Your comments are much appreciated and welcome.

If this post is of help to you, kindly click the like button and recommend use to friends. Don’t forget to subscribe to our feed.

Don't Miss Any Post Again. Subscribe To Our Feed And Be Updated

Enter your email address below:

 

Powered by OnenaijaBlog

Comments

  1. Johann says

    Hi,
    I like your tips, well done keep the good work.
    now, I have activated windows 8 using your way and when I try to modify localhost it gives me an error message:
    “Please check if this file is opened in another program.”

    Would you know why? and how to fix it?

    Thanks

    • says

      Hello Johann,
      Thanks for the complement. If you’re trying to open your host file, you’ll need to open it using admin privilege and i assure you that it will work. so do give it a try and let me know how it goes.

  2. Johann says

    Thank you very much, it works well.
    I did try to bare a website using hosts and it works but is there a way to redirect it to a different website instead of the error message below?:
    “XML Parsing Error: undefined entity
    Location: jar:jar:file:///C:/Users/Johann/AppData/Roaming/Mozilla/Firefox/Profiles/2o7yigt0.default/extensions/speedtest@gotomyhelp.com.xpi!/chrome/speedtest.jar!/content/netError.xhtml
    Line Number 392, Column 33: &netOffline.longDesc;
    ——————————–^”

    Thank you for your help

  3. vicky says

    not working…
    this is how i added,

    # localhost name resolution is handled within DNS itself.
    # 127.0.0.1 localhost
    # ::1 localhost
    # 127.0.0.2 http://www.amazon.com

    but after saving, i’m able to open amazon!!!,,,how to block it?

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>