Are you looking for ways to block access to a website? Maybe, it’s because the site has questionable or objectionable content that might pose harm to people such as children. Other times, the site is a time sink. This tutorial teaches you how to block a website without relying on browser extensions. This approach ensures safety and productivity, whether you’re protecting others or yourself.
Why Block Site Access
Most of us would agree that the Internet has its share of scary places. Some sites are rabbit holes I don’t want anyone to venture down. Aside from parental controls and security, another reason is time. Many sites can be addicting and unproductive. Some categories people have mentioned include:
- Social networking sites
- Auctions sites
- Political sites
- Adult content sites
- Explicit content sites
- Sports sites
- Finance sites
- News sites
The suggestions below on how to block websites are easy to implement. Each has its advantages and disadvantages. Most of these solutions are not browser dependent. This makes the solutions work regardless if you’re using Google Chrome, Firefox, Safari, or Microsoft Edge.
I also decided not to use any browser extensions. While some good ones are out there, I prefer not to install extra items. Browser extensions do impact your computer’s performance. The other reason is there have been some copycat extensions that are malware.
If you decide to use an extension, please ensure you’ve thoroughly checked it out with a security tool such as CRXcavator. Just because it is in a browser store doesn’t mean it’s safe. I once downloaded a 2FA authenticator program that looked like it came from Microsoft.
Try OpenDNS to Block Websites or Categories
OpenDNS is a Cisco-owned company that provides free DNS servers. Typically, your internet service provider (ISP) provides your DNS. If you’re not familiar with DNS, it’s like the Internet’s phone book. You can type in a domain name instead of typing in an IP address.
I’ve been using the service for years but didn’t realize all the features they offered. One feature is the ability to block domains or groups of domains. Think of these like a category block.
The service appeals to me for several reasons. The first is that it’s a fast DNS service. They were immune to various DNS security issues that took place over the years. Secondly, the settings can apply to a specific computer or your network. Lastly, the service is free.
If you create an account with the service, you can gain access to more features. If you need to restrict access, OpenDNS has over 50 category filters covering the usual suspects. Moreover, you can choose to block specific websites. For a small yearly fee, there are enhanced services you can get, such as faster DNS and support.
An error message will display when a browser goes to a blocked domain.
Block Access to Websites with Router Settings
Another way to block websites is with your network router. A router is a piece of hardware that directs traffic between your network and the internet. Most popular routers offer some “parental control” or “internet access policy, ” including website blocking. The key for many people may be remembering how to access the administrative panel. Usually, you can find this information on the manufacturer’s website.
The screen snap above represents the configuration panel on my router. In this case, I’m allowing access to the internet all the time except for the eBay domain I’ve blocked. These options differ between manufacturers. Like OpenDNS, the router may offer you the best option, as the changes can apply throughout your network or to a specific PC or MAC address.
Some systems also allow you to regulate Internet access based on the day of the week or hour.
Ask Your Internet Service Provider
These days many people don’t own their equipment, such as routers or modems. Instead, they lease the hardware from their service provider. Most providers offer some parental control or content control configuration. These vary considerably by provider but typically allow one or more of the following features:
- Block internet access by device
- Block sites by content filters
- Block site by the time of day
- Block site by domain
- Set screen time limits
- Create user profiles
- Create a custom block list
The downside is the documentation. My experience with ISP documentation has been that the content is geared toward network engineers, not customers. Sadly, this means you may have to call or contact technical support.
Block Access to Website Using Hosts File
This approach can be as easy or complicated as you like. I wrote a hosts files tutorial several years ago. The idea is to redirect your web browser to another IP address, such as your local machine, rather than the intended site. Usually, the fix requires you to add a line to your computer’s Hosts file using a text editor. The process is similar if you use Mac OS.
In the example above, I added a line for YouTube.com at the bottom. If I now try to access the site with my browser, I’ll get an error message similar to the one below. The message is a bit cryptic and probably wouldn’t make anyone look at your hosts file. However, one line did allow me to block access to a website.
These error messages will differ based on your browser. Here’s another example.
Hosts File Limitations
While using the hosts file is easy, there are limitations:
- You need to have administrative rights to the Hosts file.
- The block will only work for that specific computer.
- You need to flush your DNS after making changes.
- You need to preface the domains with “www”.
Microsoft & Apple Family Options
Both Microsoft Windows and Mac OS have parental control options for families. While these are great for families, they won’t help you or your habits. For example, I can’t set up a content filter for myself. They also require you to set up accounts for family members. Content filtering is just one subset of what these systems offer, so it’s worth checking them out. One disadvantage is Microsoft only wants you to use Microsoft Edge.
These suggestions aren’t the only ways to block access to a website. And remember that people will try to get around any measures you put in place. It shouldn’t come as a surprise if someone believes a site is so valuable.
Key Points and Takeaways
- Evaluate Your Needs: Determine the websites you want to block and why, whether it’s for safety, productivity, or parental control.
- Choose the Right Method: Select a method that suits your needs, such as OpenDNS, router settings, or the Hosts file, avoiding potentially risky browser extensions.
- Test your Implementation: After blocking the desired websites, test to ensure the access is indeed restricted, and make adjustments if necessary.