Open In App

How to Block Websites in Browsers?

Last Updated : 27 Feb, 2024
Improve
Improve
Like Article
Like
Save
Share
Report

Browsers are the famous tool that helps people to surf the internet. When we want to visit any website we simply go to our browser and search for that website then the browser takes us to the IP Address of that website and we become able to access that website. But if we can access all websites at every time then it can affect our productivity.

For example, if there is a student who mostly plays Online Games and his board exams are near. So in that case, if he can access the online game website then his preparation will be hampered.

Therefore, there are many scenarios in which we don’t want some specific websites to open in the browser. So for that, we block some specific websites. Before understanding how we can block any website, let us see some of the benefits of blocking any website.

Benefits of Blocking any Website

  • Enhance Security– Some websites pose security threats. This means providing any data or using that website can cause our data to leak.
  • Improve Productivity– There can be some social media websites or other sites that we mostly use for enjoyment. So opening that website during our work can hamper our productivity
  • Save from Legal Consequences– There are some website that contains illegal stuff and if somebody by mistake visits that website then it may be involved in illegal things. So we can block those websites if we want to be safe from any legal Consequences
  • Save Children from Unuseful Activity– We can block several websites like games, and movies where children waste their precious time.

How to Block Websites in Browsers?

Now we have to understand, how we can block websites in browser. So there are different ways for that. Here we will discuss some very famous ways to block websites

Method 1: Block website by editing hosts file

Before blocking any website we should know its web address and then we will follow these steps

Step 1: Run a notepad file as administrator by right clicking on it.

Screenshot-(1678)

Step 2: Now go to Open a file on Notepad

Screenshot-(1679)

Step 3: Go to Local disk C , Scroll down and find “Windows” and then go to “Windows“.

Screenshot-(1680)

Step 4: Scroll down and find “System32” and then go to “System32

Screenshot-(1681)Step 5: Scroll down and find “drivers” and then go to “drivers

Screenshot-(1682)

Step 6: Now go to “etc” folder

Screenshot-(1683)

Step 7: Now select “All Files” in place of “Text Documents

Screenshot-(1684)

Step 8: Open “hosts” file

Screenshot-(1685)

Step 9: Now write IP by increasing the last octet of localhost IP by 1 with the website’s address that we want to block. Suppose localhost’s IP is 127.0.0.1 and we want to block facebook.com

So simply we will write 127.0.0.2 www.facebook.com

If we want to block another website then write IP by increasing previously wrote IP’s last octet by 1. Means for next website we will write 127.0.0.3

Screenshot-(1686)

Now facebook.com will be blocked. If we want to unblock facebook.com we can simply remove the added line in hosts file.

Method 2: Block website by using Browser Extension

We are using Chrome as a browser. So we will block websites on chrome by using chrome extension.

Step 1: Open your Chrome Browser and Go to Chrome Web Store

Screenshot-(1687)

Step 2: Search for “Block Sites

Screenshot-(1688)

Step 3: Pick any extension and click on “Add to Chrome

Screenshot-(1689)

Step 4: Now add the domain name of the website that you want to block

Screenshot-(1690)

Now, After adding the URL of the websites you can directly block them in your Chrome Browser and you can follow the steps to block the website in other browsers you are using such as Firefox and Brave Browser.

Conclusion:

We have discussed two methods to block the websites because blocking websites can be a useful tool for anyone seeking to improve productivity, enhance security, and protect themselves from harmful or time-wasting online content. Whether you’re using the hosts file method for manual control or a convenient browser extension for ease of use, the power to limit distractions is within your grasp.


Like Article
Suggest improvement
Previous
Next
Share your thoughts in the comments

Similar Reads