These days, when we are about to break the record of hacker attacks just set, at the end of 2021, online dangers are everywhere, in the form of apps, e-mails, messages. Without forgetting the malicious sites.
There are several reasons why you may want to block certain certain portals on your PC. Some spread viruses, others contain explicit content, some even try to steal your data
There are several ways to block websites, yes. The choice is wide: only on specific browsers, on the entire operating system or even on the network router. And the more you have, the more you put.
A simple and intuitive path
If you wish to check theaccess to websites on a single computer, you can set blocking at the operating system level. A method that is not too difficult to set up and will work on all browsers. One of the backbones of the Internet is the DNS system which translates easy to remember (and type) names like www.google.com in equivalent IP addresses (220.127.116.11).
While using DNS servers to access websites, your computer also has something called a HOSTS file which may have this information stored locally. This can be used to disable access to unwanted websites. A valid method is with Windows 7 that with Windows 8.
First you need to make sure you have administrator access on your computer. Then log in using an administrator account and go to C: \ Windows \ System32 \ drivers \ etc \. Then double click on the file named “hosts”: select Notepad from the list of programs to open the file. Click OK. The last two lines of the hosts file should read “# 127.0.0.1 localhost” and “# :: 1 localhost”.
In case you cannot edit the file, you need to right click on the file named hosts and select Properties. Then go to the Security tab, select the administrator account and click on the Edit button. In the pop-up, select the account again and select Full Control. Click Apply> Yes. Now click OK in all pop-ups.
At the end of the file, you can add the addresses of the websites to block. To do this, simply add a line to the end of the file, with 127.0.0.1 and then the name of the site you want to block – this will redirect the site name to your local computer. To block Google, for example, add “127.0.0.1 www.google.com” to the end of the file, but without the quotes. You can block as many sites as you want this way, with a good note: remember that you can only add one per line.
Once done, press the close the hosts file button, then click Save. The last step is to restart your computer to make the changes effective: all the portals you have decided to block are no longer there.