How to block websites by editing the Windows Hosts file .
The location of the windows host file depends on your operating system’s version .
For Windows XP, Vista , Windows 7 and Windows 8 : C:\WINDOWS\system32\drivers\etc\hosts
For Windows 2000 : C:\WINNT\system32\drivers\etc\hosts
Follow these steps to block websites with this method . For this method we will take Facebook as an example .
- Browse the location of the Windows host file
- Open the hosts file using the notepad or any text editor .
- Find the line “127.0.0.1 localhost”
- Add a line “127.0.0.2 www.facebook.com” under the “127.0.0.1 localhost” as shown below in the screenshot .
- Since this method blocks the exact url address you entered in your hosts file . you also need to add another line incase somebody enters facebook.com without the www “ 127.0.0.3 Facebook” . take a look at the screenshot below for reference .
- If you want to block more website then you need to add 1 to the internal ip ( 127.0.0.1 ) and specify the website URL address right next to it with a space . Lets add YouTube to the list of blocked websites . For that we will take “127.0.0.4YouTube” and add it to the hosts file .
- Save and replace the hosts file in the etc folder without any extension .
- No open command prompt by pressing Windows + R key on the keyboard . type “ cmd.exe “without the quotes in the run window and press enter .
- In the command prompt type “ ipconfig /flushdns “ and press enter . Now we have successfully blocked facebook and youtube access from your computer .
- Reopen any web browser and enter facebook’s url address to confirm . Now the websites specified in the hosts files are blocked .
If you want to unblock the websites again , simply delete the entries you made earlier and save the hosts file .
But if your childrens are tech savvy they can easily edit the hosts file and unblock the blocked sites . Lets check another method which should not be accessible by your tech savvy childrens . Further using this method of blocking websites lets you implement the block on multiple devices connecting through your router , which means your childrens cannot access the blocked sites on their cellphones and laptops too .
Tidak ada komentar:
Posting Komentar