Setting Up a VPN on a Virtual Router for MacOS

Setting up VPN on virtual router MacOS graphic
Click here for a summary of this article
Setting up a VPN on a virtual router: MacOS

Do you want to use a virtual router on your Mac, e.g. to connect your Apple TV to a VPN? Using the settings on your Mac, this is easy.

  1. Make sure your Mac is connected to ethernet with an internet cable.
  2. Set up a VPN from the System Preferences menu on your Mac.
  3. Set up your Mac from the same menu to share your internet connection.

Once you’ve set up the VPN, you can turn on the virtual router. A VPN that works very well with virtual routers is ExpressVPN.

Want to know whether your Mac is suitable to function as a virtual router? Or would you like to learn more about how the setup works on MacOS? Read our full article below.

There are several devices that don’t have any built-in software for VPN connections. However, these devices are connected to the internet: think of an Apple TV or a Chromecast. If you still want to use a VPN with those devices, you need to set it up on a router or a virtual router. In this article, we’ll discuss how to set up a VPN on a virtual router on MacOS. More information can be found on other pages on our website, such as how to set up a VPN on a regular router and on Windows.

What is a Virtual Router?

A virtual router is software that allows you to simulate a physical router on your computer. This allows you to set up a WiFi network on your computer, which can be useful if you don’t have a normal router, for example in a hotel room.

With a virtual router, you can set up your computer’s WiFi receiver to let it transmit WiFi signals instead of receiving them. Nowadays, this can be done quite easily on different devices. Many people are familiar with the “Personal Hotspot” function of iPhones. A virtual router works in a similar way: it’s just your computer that becomes the WiFi hotspot instead of your phone.

Virtual Router VPN on Smart Devices

What Can You Do with a Virtual Router on MacOS?

A virtual router allows you to connect all of your devices to the internet without using a regular router. This is useful if you only have one wired internet connection. You can also set up a VPN on this virtual router. This means you can secure any devices that don’t support VPN software themselves. Think of your Apple TV, Chromecast, Amazon Fire TV stick, or particular smart TVs.

Why Set Up a VPN on a Virtual Router?

There are a few reasons to use a virtual router. First, you may want to share your internet connection with other devices, because there is no wireless internet available. Secondly, using a virtual router is completely free, as long as you already have a computer that supports it. Therefore, some people use it instead of a physical router in order to save money.

However, the main reason for setting up a virtual router has to do with security considerations. Some devices, such as Apple TV, don’t support VPN connections. To protect these devices anyway, you need to run their internet traffic through a router that encrypts this traffic. This is where a virtual router can help.

Requirements for Setting Up a Virtual Router with VPN (for macOS)

To install a VPN on a virtual router, you’ll need a couple of things:

  • A macOS computer (with a WiFi adapter, which almost all of them have nowadays)
  • An ethernet cable (with an adapter to USB if your Mac doesn’t have an ethernet connection)
  • A VPN subscription (with a trustworthy provider such as ExpressVPN, NordVPN, and CyberGhost)

The ethernet cable is needed because you can’t both receive and transmit WiFi on most computers at the same time. In other words, you’ll only be able to get online through the cable, while your WiFi is transmitted to other devices via your Mac.

How to Set Up a VPN-Secured Virtual Router on MacOS

Once you’ve got the essentials, you’re ready to go. Setting up a virtual router with a VPN takes two different actions. First, you need to set up the VPN connection, then you need to set up the router. For complete protection it’s important you set it up in this order, otherwise, your internet traffic won’t always run through a protected VPN connection.

Setting up the VPN connection

Setting up the VPN must be done manually, otherwise, it won’t be possible to share the connection with other devices. Follow these steps to activate a VPN on your macOS computer:

Step 1: Make sure you have a VPN subscription with a good provider. For (virtual) routers, we’d advise ExpressVPN. This service is fast, reliable, and has many options.

Great discount on annual subscription + 30-day money-back guarantee!
  • Very easy to use VPN
  • Perfect for anonymous browsing, downloading, and streaming (i.e. Netflix)
  • 3000+ servers in 94 countries
Visit ExpressVPN

To read more about the best VPNs for macOS, read our top three right here.

Step 2: Go to “System Preferences” on your Mac and click “Network”.

Step 3: Click on the “+” icon to add a VPN. Then choose “L2TP over IPSec” (this protocol is most commonly used for sharing a VPN connection) and name the VPN connection under “Facility name”.

Step 4: You can now adjust the settings of the VPN. Under “Configuration”, choose “Default”. Find the server address of the server you’d like to use on the website of your VPN provider. Enter the address into your settings. Finally, enter the account name of your VPN subscription. Then click on “Identity control settings” and enter your VPN account’s password.

Enter the “Shared secret” on this same page. The other options can be left blank. Click on “Ok”. You’ll now return to the VPN settings page.

Step 5: Click on “Advanced settings” on the VPN settings page. You’ll see a window with different options. Click the option “Send all traffic through a VPN connection” here. If you don’t do this, the internet traffic from connected devices will still run through a normal connection. After that, click “Ok”.

Step 6: You’ll be back at the VPN settings screen. Click “Apply” and “Connect”. The VPN connection is now set up correctly.

Setting Up a Virtual Router on MacOS

Virtual routerSetting up a virtual router on macOS is a breeze. It’ll just take you a few minutes. Here’s a step-by-step guide to easily set up a virtual router with your Mac:

Step 1: Make sure you are connected to the internet via an ethernet cable. You can check this under “System Preferences” > “Network”. This is necessary because you can’t receive and transmit WiFi at the same time on a macOS device.

Step 2: Go to “System Preferences” and click “Share”.

Step 3: A new screen appears. Here, you can select either “USB ethernet” or “Ethernet” in the dropdown menu next to “Share your connection from”. Some Mac devices don’t have an ethernet cable input, in which case you’ll have to use a USB to ethernet adapter. With the connector, you choose USB ethernet. If you don’t use an adapter, simply choose Ethernet.

Under the option “To computers using” choose “WiFi”. Now click on “WiFi options”.

Step 4: You’ll see a new menu. Here, you can specify what the network name should be. Optionally, you can set a password by clicking on the security option. You can simply leave the channel at 11. Now click “Ok”.

Step 5: You’ll find yourself back at the menu. Click on the box next to “Internet sharing”. If you have gone through all the steps correctly, the virtual router will now be visible to other devices. (Again, please note that you need to enable the VPN connection before turning on the hotspot if you want a secure connection for all your devices).


In this article we discussed how a virtual router can help you when you don’t have a regular router to work with. Besides that, setting up a virtual router on MacOS in combination with a VPN secures all of the devices connected to it. It’s important to first set up the VPN, and then the virtual router. Once you’ve set up the VPN on your macOS device, you can easily secure all of your devices with an encrypted connection.

Setting up a VPN on MacOS - Frequently Asked Questions

Do you have a problem setting up a virtual router with a VPN on your Mac? Take a look at the frequently asked questions below. Click on a question to see a quick and accurate answer.

A virtual router basically turns your Mac into a WiFi hotspot. The computer is then able to transmit WiFi connections, so other devices like your iPhone or Apple TV can use your Mac’s secure internet connection.

Setting up a virtual router on your Mac is done through the settings in the operating system. There is integrated functionality in MacOS, both for transmitting a WiFi signal and setting up a VPN. It’s crucial to first set up the VPN and then the virtual router. Otherwise, there is a chance your internet traffic will remain unsecured.

Yes, you can. Just like your regular internet connection, you can also secure your Mac’s virtual router, or hotspot, with a VPN. By enabling a VPN on the device that acts as a virtual router, you can secure all of your internet traffic through that device.

A VPN that almost always works perfectly is ExpressVPN. If you want to use it with your Mac as a virtual router, all you have to do is change a few settings in MacOS. ExpressVPN’s speed is incredibly high.

If you use a virtual router with a VPN, all devices connected to that router are automatically protected. This way you don’t have to install the VPN on every device. This often means that you can protect more devices than your VPN subscription would otherwise allow. Furthermore, you’re able to connect devices like Apple TV, Smart TV or Google Chromecast through the VPN. This gives you more options to stream safely and privately.

Tech journalist
Erik was educated in the humanities, after which he started to investigate technological and online culture. Specifically, he is interested in privacy and net neutrality. Erik has worked as an editor, copywriter and translator for several platforms, with technology as a recurring theme.