hit counter script

Block Site Using Hosts File

Block Site Using Hosts File – Now you can suspend/block specific websites on your computer on Windows running OS. Why would you want to block websites because sometimes we get addicted to a few websites and spend hours without realizing that our time is being wasted? What a shame and we keep wasting more and more time every day but we don’t bother to block those sites that waste our time. This is not a tutorial but more of a quick tip to block websites with Hosts file in Windows.

I prefer to block websites that waste our precious time and don’t let us do what is worth our time. So I thought if I could give you a pretty good way to block websites using Hosts files in Windows operating system.

Block Site Using Hosts File

A hosts file is one of the most important files in the Windows System32 folder that helps us manage hostnames to IP addresses. It is a plain text file. Originally a file called HOSTS.TXT. I am going to guide you to block websites using Hosts file in Windows so that you can easily block the time consuming websites.

How To Block Websites In Google Chrome For Pc And Android

Note:  That host file is hidden by default and to access host file you need to go to folder options and check “show hidden files and folders” now when you try to modify the file (make sure the read-only file attribute is unchecked) windows WRP will kick in with UAC. Social media has become a pervasive force on the Internet. I think back to when I first used the Internet when the only social media was IRC, message boards and MSN messenger.

Aside from being a distraction, the amount of trackers that social media sites inject into news, entertainment and other sites is a concern.

Blocking the hosts file on your operating system is much more efficient and faster than using a browser plugin to block websites and content. Since your machine will kill all network and DNS requests at the OS level instead of waiting for the browser extension to catch any HTTP requests and resolve them to a blocked address.

IP address is preferred over localhost as it is a non-resolvable meta address (a flag used by the operating system).

How To Block Websites In Chrome

The example above will block the main hostname for Twitter, Facebook, etc. However, many of them have CDNs and other routable addresses for trackers and media. I would recommend using this list on Github here.

You can then copy and paste it into the following hosts file depending on your operating system (you need elevated sudo / gksu privileges).

Once you save the edited hosts file, be sure to run the associated command with your operating system to ensure you start blocking social domains immediately.

Note: this solution is limited to the machine you are using, if you want a more comprehensive solution is to set up pi-hole and do all DNS queries on your LAN there. Why do you want to know how to block websites? Maybe you want to keep your children safe on the Internet? Maybe you want to block distracting websites so you don’t procrastinate? It can also be used to block tracking websites that are embedded in ads.

How To Leverage The Hosts File To Block Ads

The text below can get a little technical, especially if you’ve never gotten into the nitty-gritty of Windows system files. If you want a quick overview, be sure to check out our short and easy to follow YouTube video first.

Have you heard the term DNS (Domain Name System)? It refers to a system of files distributed around the Internet that help resolve domain names as in its actual Internet Protocol (IP) address, which happens to be It helps your computer know which server to talk to when you want to see this page.

Before DNS came into existence in 1984, this was done through a local file on your computer called the hosts file. At that time, computers were not connected to many other computers. At most we might have connected a couple of dozen. It was easy to keep all that information in a plain old text file. The hosts file lives on today.

The hosts file allows the computer to look up other computer names, such as localhost, or domain names, such as, and the IP number for them is right next to the name in the file. It’s kind of like how your friends’ names are linked to their phone numbers on your phone. You don’t need to remember or enter the number, just find the person’s name.

How To Block A Website Using Host File

Before we go any further, it is important to understand that some IP addresses are reserved for local use. That means they can only be used to point to your computer and the devices on your immediate network. That means everything before your communications connect to the Internet.

For example, the IP address always means the computer you are working on, also known as localhost. Try typing it into your browser. It will probably bring up a blank page.

Also understand that www.website.com and website.com are not exactly the same thing. In order for both to take us to the same website, both must resolve to the same IP address.

Enter the local host IP Press the tab key and type facebook.com. Press Enter to go to the next line. Create a new line like the one above, but use www.facebook.com instead of just facebook.com.

How To Block Websites On Microsoft Edge 2020 (chromium)?

Open command prompt and run ping facebook.com and then run ping www.facebook.com. You should see that the IP address it is trying to ping is

Now open your browser and go to facebook.com. It can still be loaded! Why? Facebook’s real IP address may still be in the browser cache, and the browser will use that IP first. Clear your browser’s cache and try Facebook again. You should now see an error page.

You can try redirecting the site to another IP address, but these days it won’t work well. Malicious editing of the hosts file used to be a common attack by hackers. Now browsers look carefully for certificates to prevent this. But you can still try.

Another way to not see an error page is to install and set up a web server on your computer and let the hosts file point to it. Maybe make it show a page that says, “Get back to work!” or lists some of your goals as motivation to stay off social media.

How To Block Website On Edge Browser For Windows 10?

You can use the same technique, but paste the URLs of various malware and tracker ad sites. There is a ready-made hosts file with malware and ad pages that you can copy and paste into the hosts file. At the time of writing, it was last updated in March 2020.

Guy has been published online and in print newspapers, nominated for writing awards and quoted in scholarly articles for his ability to talk technology to anyone, but still prefers analog watches. Read Guy’s full biography

Did you like this tip? If so, check out our YouTube channel from our sister site Online Tech Tips. We cover Windows, Mac, software and apps, and have a bunch of troubleshooting tips and how-to videos. Click the button below to subscribe! Block Adobe Photoshop CC activation outgoing link using windows host file or firewall is a common question for everyone.

I’m not a professional graphic designer, but sometimes I like to play around with Adobe tools like Photoshop CC. Since I don’t use it for professional work, I decided not to buy it. Instead, I use the trial version.

Block Adobe Photoshop Cc Activation Using Windows Hosts File

But almost everyone knows that Adobe allows a 30-day trial, then it will continue to show activation messages.

So, as a hobbyist designer, how can I use Adobe Photoshop CC without activation? Yes, there is a way. You can use either the Windows firewall to block all outbound links from Adobe, or you can also use the Windows hosts file to block these URLs.

Today I won’t share how to block outbound links for software using firewall because I don’t want to write a very long article. You can search on Google how to block software or block Adobe Photoshop CC using Windows Firewall.

While there is no one-size-fits-all approach to designing with Adobe Photoshop, I assure you these tricks will save you time.

How To Block Websites On Windows 10 Pc/laptop Using Host File In 2021

Update Note: Many of my readers are asking for solutions to activate Adobe Photoshop and other Adobe products like Adobe Premiere Pro, After Effects, Illustrator, etc. I know it is quite expensive for us to buy from the original vendor. That’s why we use almost all premium software for free. I will share the activation method under this post very soon.

By the way, you can use this method to block Windows host for all Adobe software like:

And you are looking for a way to block the use of Windows hosts files, then this article is for you. Below you will get proper way to block Adobe Photoshop CC activation using windows host file.

Step one: First, open notepad with admin permission. Search for notepad and right-click on it to see the option to run as administrator permission.

Ways To Block A Website On Your Computer

STEP Two: After opening the Notepad window, click on File

Using hosts file to block websites, block site using hosts, how to use hosts file to block websites, best hosts file to block ads, how to block site using host file, block spotify ads hosts file, block sites hosts file, how to block website using host file, block websites using hosts file, hosts file block ads, how to block sites using hosts file, how to block websites using hosts

Leave a Reply

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