How to block a website using Hosts file

The location of the hosts file depends on your operation system.

Windows XP, Vista and Windows 7 C:\WINDOWS\system32\drivers\etc\hosts

Note! Make a backup of the hosts file and put it somewhere safe, in case you mess up.

1. Open the hosts file using Notepad or other plain text editor.
2. Find the line 127.0.0.1 localhost
3. To block, for example, the website YouTube, add this text under 127.0.0.1 localhost: 127.0.0.1 YouTube
4. Save and close the Hosts file.
5. Reboot your computer to apply the changes.
6. Try to open YouTube (for example) into a browser.

How to block a website on Internet Explorer

Facebook Comments

Post Author: Ahmed Zaid

Leave a Reply

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