Routing only specific traffic through VPN

I’m in a situation where my ISP throttles only video streams (Rogers, Canada) on my 5G home internet. Any video streams are throttled to 3mbps (720p). When I use a VPN I get my full 50mbps speed even with Netflix and YouTube.

I’d like to setup routing if possible so that I don’t need to setup and toggle VPN constantly on all streaming devices in house. Is there a way to route traffic for only Netflix, Prime Video, Disney+ and YouTube through a VPN (I have PIA and Nord subscriptions). I’d like the rest of traffic to remain outside of VPN for latency reasons.

Any help is appreciated, I have a UDM Pro if that that helps any.

Yeah you can - you can route by domain name or IP or Region.

Assuming you have already set up the VPN side in there.

Goto Routing

Traffic Routes > Create Entry

What to Route = Specific Traffic

Category = Domain or IP

Can Batch Add with IP from a text file list too if you like.

Device/Network - can select specific clients or the network entirely.

Interface - select your PIA VPN interface.

I still think it is odd that the same question came from three different accounts on this subreddit within a short amount of time but I don’t browse this one so often so maybe it is asked all the time.

But anyway, here is a how to video showing what you are asking:

crosstalk solutions

I am trying to do the same thing but cant get it to work. If I route all traffic it work, but if I specify a domain (have tried a bunch) it doesn’t. Anyone have similar issue?

This was really easy! Thanks for the guidance! I added my TV and Nvidia Sheild to the VPN route via device filtering, which solves the problem. 4k DV is back in action! I tried using domains from NETIFY.ai but it didn’t seem to hit all of Netflix and YouTube routes.

Do you use a custom DNS?

I had the same problem, when I saw that on the Ubiquiti website, it specified that for Routes based on Domains, the Unifi Gateway needs to be a DNS Server.

I use Pi Hole, before I set it on each VLan, I had to specify it in Wan, the problem was that I lost the ability to customize the block list for each network or device individually.

Source: https://help.ui.com/hc/en-us/articles/12566175125783-UniFi-Gateway-Policy-Based-Routes

I am having the exact same issue with no luck. All traffic is fine, but domain or region simply doesn’t work. I cant seem to find what the issue is - I have a UDMP SE with latest os.

Hey no problem, glad it helped. You could potentially get them from Netflix themselves as they do list them here (for US)

check the comment I replied to our friend, I hope it helps.

https://www.reddit.com/r/UNIFI/comments/1azuxug/comment/l0oxn9t/?utm_source=share&utm_medium=mweb3x&utm_name=mweb3xcss&utm_term=1&utm_content=share_button