How to Unblock Websites on Mac Terminal

If you have been using the Mac to surf the internet for a while now, then there might have been times when you aren’t able to access a website, or it just never loads appropriately. Although it can be an issue within the website, most of the time, it is due to the website being blocked on your end.

We understand how inconvenient this can be because it affects your productivity and slows your workflow. But worry not, as in this article, we will see how you can unblock websites on Mac Terminal.

Before we begin, let’s talk about why websites get blocked in the first place.

Why Do Websites Get Blocked

There could be many reasons behind a website getting blocked. However, more often than not, websites get restricted because they contain destructive content, they deal with banned substances, and they contain anything that has been rated harmful in general.

Although a website can be blocked in multiple ways, there are three primary levels that play a role in restricting someone’s access to a website. The levels include computer, network, & governmental/ISP, and each of them holds a certain amount of power and authority.

How to Unblock Websites on Mac Terminal

Now, if you own a Mac and your restriction is based on the computer level and is blocking certain websites, there is a way to get them unblocked using the Terminal on Mac. We are about to lay down the steps that you can follow to do the job.

The first step on the list is to open the Terminal application on your Mac. Here’s how you can do it:

  • Navigate to your Launchpad.
  • At the top of the screen, type Terminal into the search field and press Return.
  • Once the application appears, Double-click on it to open the app.

Once inside the Terminal application, the second step requires you to open the host file. Here are the steps to do it:

  • Paste the following command sudo nano /etc/hosts and hit Return.
  • Now it will prompt you for the administrator account passwords, fill in the respective password, and press Return.
  • After you are done, the host file will open on your screen and it will give you editorial access.
  • In the host file, you should be able to see all the websites that are currently blocked on your Mac. Simply locate the respective website you wish to unblock and move your cursor via the keyboard keys to the start of that line.
  • Once you know which website you want to unblock, you have two options to unblock it. You can either delete the whole line of the respective website or you can put the # symbol before it. 

Once you are done with your edits, the next step is to save and exit the file. Follow these steps to do it:

  • On the Terminal screen, press Control + O and then tap Enter to save your edits.
  • Finally, press Control + X to exit the Terminal application.

The last and final step is to head back to your browser and test the respective website again. It should be unblocked and working.

If you used the second step to unblock the website and added a # symbol, then keep in mind that you can easily block the website whenever you want in the future. All you have to do is remove the # symbol from the website.

Related:
How to Rename File or Folder in Mac Terminal

How to Unblock Websites on Safari

Safari is the most popular browser available on the Mac, but sadly even it can’t access restricted websites without additional help. Luckily, the fix for this is quite simple, as a VPN can solve all of these issues without breaking a sweat.

A VPN masks your IP address and provides you with a new one, it can easily bypass any regional restrictions. In addition, it also protects your online anonymity and offers protection against hackers and malicious individuals.

Some of the most popular VPNs for Safari include:

  • NordVPN
  • Surfshark
  • IPVanish
  • PrivateVPN
  • Atlas VPN
  • CyberGhost
  • ExpressVPN

How to Unblock Websites on a Mac Using Parental Controls

One of the reasons why you might be facing website restrictions is parental control. It can not only stop your access to a website, but can also be used to create additional restrictions like creating time limits and schedules which revokes your internet access as soon as the limit ends. 

Luckily there is a way to disable it, and we will see the complete method to do it in the steps explained below:

  • Tap on the Apple icon in the top left corner of the menu bar and click System Preferences. It can also be found in the Applications folder via the Dock.
  • Navigate to Parental Controls from the list of options. If you can’t find it, simply search for it using the search bar in the top right corner of the System Preferences window.
  • Once done, you will see a list of existing accounts on the left-hand panel. Click on your respective account. If asked for, then you need to provide your administrative password to access the next window.
  • Now in the next window, click on the Web tab to see the list of restrictions. If you run an older version of macOS, you will find it as the Content tab instead.
  • Once on the Web tab, scroll through the list of the options and look for Website Restrictions. 
  • Either click on the Allow unrestricted access to websites option or choose the option that works best for you.
  • If you also have additional restrictions, you can visit the Time Limits tab and adjust all the limits according to your requirements.

That’s it, you have successfully unblocked websites on the mac using parental control.

How to Unblock Websites on Chrome

Just like Safari, sometimes websites get blocked on Google Chrome due to various reasons as well. It becomes extremely annoying especially for workers who have to travel a lot to different countries and they end up facing geo-restrictions.

If you are someone who is having troubles with this, then we have researched five different tips that you can use to unblock websites on Chrome while on the go. 

  • Bypass the Chrome warning
  • Remove websites From blocked lists 
  • Use a Virtual Private Network
  • Edit the Host File
  • Disable Windows Firewall

Related:
How to Reset Terminal on Mac

3 Ways to Block Websites on a Mac

Now that you know various methods to unblock websites on Mac, let’s discuss how you can do the opposite of it. Below are three ways that you can use to block websites on a Mac:

1. Using the Terminal

The first method to block a website revolves around the Mac application, which can be a little complicated for some users. But here are the steps to execute it without running into any issues:

  • Open the Terminal application via the Launchpad.
  • Open your Host File by pasting the following sudo nano /etc/hosts command and hitting Return. If prompted, enter your administrator password to access the file.
  • Once inside the file, locate the 127.0.0.1 localhost line and click at the end of it.
  • Tap Tab and insert the website URLs you want to block on your Mac.
  • Save and exit the file using the following commands respectively. Control + O (to save), hit Return (to save with the existing file name), and finally Control + X (to exit the editor).
  • Finally, visit the website on your browser. You should no longer be able to access it.

2. Using Parental Controls

The second method on the list is to use the Parental Control feature to block certain websites on Mac. Similar to the first method, it can also be a little difficult for some users, but nonetheless, the following steps should make it easier for you to do it on your own:

  • Click the Apple icon on your menu bar and select System Preferences.
  • Once inside System Preferences, select Parental Controls.
  • Select your Child’s account (if absent, click Create a new account with parental controls ) from the left-hand panel and click Enable Parental Controls (you can’t set parental control on an administrator account).

Open the Web/Content tab and scroll down to Website Restrictions.

  • Select the option that fits best to your needs. You can block certain websites or only allow specific websites to be accessed.
  • You can set additional restrictions by heading to the Time Limits tab. It allows you to create schedules and limits for internet usage for your child.
  • Save your changes and revisit the browser to confirm whether the respective websites have been blocked or not.

3. Using a Third-Party Application

If the above methods seem too tricky, then worry not as there are more straightforward methods. One includes using a third-party app like Cisdem AppCrypt because it does a fine job at restricting all harmful websites.

Umar Farooq
Umar Farooq
Umar Farooq is a digital Evangelist having right commands on writing, also he is a web developer. He has a BS(Computer Science) and now he is Full-Time writer of TechanZone.

Popular on TechanZone

LEAVE A REPLY

Please enter your comment!
Please enter your name here