Table of Contents
How to Block Website in Windows 10/11
How to block website in Windows 10/11 has become a common question these days. In this digital world, as much as we get to learn, we also get to see some wrong information or content through websites..
Students have to study computers for education. Be it school, college, educational institute or office. Everyone has the same issue whether they are students or employees, whether they should be able to pass their time or not be able to see any wrong content. Hence, the question of How to block website in Windows 10/11 arises here.
Disclaimer:
The methods shared in this post are meant to help you learn how to block website in Windows 10/11 safely. Please be careful while changing system settings, and only do so if you’re comfortable. We’re here to help, but we can’t take responsibility if something goes wrong.
Click here to learn How to make Bootable Pendrive of windows 10
In this post I will give you 3 methods How to block Website in Windows 10/11 without any third party software through which you can easily block any website. Or you can block all websites and give permission to access some websites or only one as per your requirement. Let’s Start
Method 1 :- Edit in Host File
open notepad as Administrator-
You will have to open notepad in adminstrator because your file will not be saved without admin authority.
Press window button and type notepad-right click on it- click Run as Administrator. see Image below.

After opening Notepad, go to File and then click on Open

I am giving you the complete Path where you will find the file in open and below there are step wise step images which you can see and reach the file.
open-This PC / C drive or (in which your windows files) -/Windows / System32-/drivers-/etc/host
Make sure , Below in Dropdown menu “All Files” selected without its Host file will not be shown.
click on image shown below its will be open and zoom and see all steps or path which given below.
Make sure , you have selected “All files” in bottom of file open box now double click on host file .

Here you can see between the blue lines, you have to write the text which is written here. # 127.0.0.1 After this, keep the website name which you want to block on your PC. Websites can be Search in two ways, one with www. and one without www. for example facebook.com and www.facebook.com, you have to type it in both the ways as shown in the image.

You can block as many websites as you want by typing them. Save the file and test it in any browser. Whatever you have block has been blocked in your PC now .
How to unblock These websites.
Simple Whatever website names you have added, delete those lines in the hosts file and save the hosts file, the website will be unblocked.
Method 2:- Widows Defender Firewall
How to Block Website in Windows 10/11 with firewall
You can also block websites one by one using this method.
But the method gets a little bit technical. In this we put the IP address of the website in place of the website name, every website has an IP address, suppose we search Google “www.google.com” The request is sent by the browser to DNS (Domain Name System) and asks this site named google give me its IP. It sends the request to the browser, then the browser sends the IP to the server then the page opens in response. If you are not difficult to understand leave that but how to find out the IP of any site question arise here.
Let start how to find IP Address of any website.
Press Win + R to open the Run dialog, then type cmd and hit Enter to open the Command Prompt. Look at the image below.


Now type command nslookup websitename hit enter
example nslookup facebook.com
here you find 2 IP one ipv6 and second is ipv4 . if you not from computer science background don’t be confuse what is IP Address no need to know technical terms. see the image below.

Now you have found out the IP address. Now go to the Control panel and click on Windows Defender Firewall. In Control Panel set Large icon to small icon then click on Internet Option. See images Below



Now Click on Advance Setting then click on Outbound right click on it and click set New Rule.

After Click on ” New Rule” this Page is open see Image of that below.

Click on “Custom” this Page is open see pic of that below for next step

Make sure here All Program Selected then click on Next Button.

Make sure here Protocol Type is Selected “Any” then click on Next Button.


Here You can ignore first option and click on “These IP Addresses” in Second option ” Which remote IP addresses does this rule apply for” Now Click on “Add” button in under this option.
Now we have the website IP Address which we had obtained earlier through Command Prompt.Copy that IP address one by one and Paste it here “These IP Addresses” box one by one , Remember, Just like we wrote two names in the host file in the Method One. Similarly here also we have to enter both Ipv6 and Ipv4 IPs for one website. That is why I told a little about Ipv6 and Ipv4 so that you do not face any problem in understanding later.
click on “Add” a new dialog box open .copy that IP and paste it in and click ok again click on add button for paste second IP of facebook in this Image i paste IPv4 ” This IP Addresses or subnet.


Now I have pasted Ipv4 click ok . Now press “Add” button again to insert Ipv6.

Now I have pasted Ipv4 and IPv6 one bye one and clicked OK button. You too have to do the same

Click on Next Button.

Make sure select ” Block the connection“.Click next.

Click on check box Or by default all these three boxes will be checked and now click on Next button.

Give the name to Rule you created and click on Finish Button. Thats it your work is complete now facebook.com is blocked from your Computer.
Similarly, you can create as many rules as you want or you can put IPs of different websites in one rule and Block them from your computer.
How to unblock block websites

If you want to unblock the website which is blocked then you can delete or disable it by right clicking on the rule you created.
Method 3:- Using Internet Options
Whatever we have learnt in this blog is about blocking single or multiple websites. In method 3 we will learn to block all the websites, except that only those websites which we allow will open in our browser.
Sometimes we have an environment like office or school, educational institute where it is required that students or employees can access only the important websites and no other websites, this method can be used there.

Go to the Control Panel , Like I mentioned earlier shift large icon to small icon and find internet options.

Now Click on Connection Tab after click on LAN Setting Button bellow.

After Click LAN Setting , Leave the Automatic configuration as default setting. Click on the check box of Proxy Server below and add 127.0.0.1 in the Address column and enter 80 in the port. By default, 80 will be written in the port. If not, fill in 80. After that click on Advance.

After Click Advance , Here leave the Server settings as they are by default and as an Exception insert the name of the website which you want to give access in your computer, like. Facebook.com; www.Facebook.com;. Keep writing the name of the website which you want to access, Example Facebook.com; www.Facebook.com; space Google.com; www.google.com;. Make sure that the name of each website appears twice as it was done in the hosts file.
Click OK on each dialog box. Now the user can access only the website you have given access to.
How to Unblock:-

Simple Uncheck on Proxy Server and click on ok each Dialog Box. Websites Blocking will be Disable .
Method 4:- Use Third-Party Apps/Software
All the methods of How to block website in Windows 10/11 we have learned earlier are Windows features. But we can do the same thing with third-party software or extensions. Their names are:-
- Cold Turkey
- FocusMe
- Freedom
- BlockSite ( Browser Extention.)
These apps offers scheduling , Password Protection for Better Control . You Can Also try these.
Conclusion
Blocking sites on Windows 10 and 11 is very simple and can be done using multiple methods including modifying the hosts file, using the Windows Defender firewall, Proxy Server or even third-party software. Regardless of the method chosen, after these steps are done, you can better control your surfing habits, therefore making your experience on the computer more effective and safer. However, all of these methods can be bypassed using public web proxies and Virtual Private Networks (VPNs).
If you still want more tips on Windows 10 and 11 and other tricks, make sure to keep an eye on our blog. Remember that learning How to block website in Windows 10/11with ease will drastically improve your daily activities on a digital level.
How did you like this blog, your real experience in comments and if you like this content please share. All share buttons given below
Frequently Asked Questions
Read this Blog you will learn 3 method How to block website in Windows 10/11 step by step. you will also learn how to block single website in your PC and you will learn in Method 3 how to block all websites expect you approve to allow.
In this blog How to block website in Windows 10/11 all steps are simple you no need to download 3rd party software to do this. All of this is Windows feature. Once you read all methods you will block websites you want to without Technical Knowledge.
you can use Public Web Proxy or VPN to access Block websites.
No, in this blog it has also been told that the blocked websites are in Your Computer which are Block by Yourself. How to unblock them.
No, you don’t need an active internet connection to block websites using any of Method we learn expect third-party Software. But after Blocking you will to check then you will need internet