Skip to content

How Do You Check VPN Routes Using Windows PowerShell?

A few read-only PowerShell commands show where Windows sends your traffic. Here is how to run them, read the columns, and tell whether the VPN is really in the path.

11 min readUpdated Nov 9, 2026By XPASS Editorial Team

How Do You Check VPN Routes Using Windows PowerShell?

When a VPN is connected but pages will not load, or a site seems to ignore the VPN completely, the cause is often routing: Windows is sending your traffic somewhere other than where you expected. The good news is that Windows lets you look at those decisions directly. A handful of read-only PowerShell commands will show the routing table, the network adapters, and the exact path Windows would choose for a given address.

This article walks through those commands in plain terms. You do not need to be a network engineer, and nothing here changes your settings. The goal is to read what is already there, understand the columns, and decide whether the VPN is really in the path. If you want the background on why several default routes can clash, read how multiple default routes cause VPN problems first or alongside this guide.

What a routing table tells you

Every Windows computer keeps a routing table: a list of rules that answer, for each outgoing packet, "which way should this go?" Each rule has a destination range, a next hop (the gateway to hand the packet to), the network interface to use, and a cost number called the metric. The basics of how packets carry destination addresses come from the Internet Protocol, described in RFC 791.

The most important rule for a VPN is the default route, written 0.0.0.0/0 for IPv4. It means "every address", and it is used only when no more specific rule matches. A VPN that carries all of your traffic usually makes sure the tunnel wins the default route, either by replacing it or by adding two more specific halves of the address space that together cover everything. A VPN set up for split tunneling leaves your normal default route alone and adds routes only for certain ranges.

So when you check routes, you are really asking three questions:

  • Which interface owns the winning default route right now?
  • Is the VPN adapter present and does it have routes at all?
  • For a specific destination, which interface would Windows use?

Everything below is a way to answer one of those. For the broader picture of how the Windows adapter fits in, see the Windows VPN network adapter.

Opening PowerShell and staying read-only

Press the Start button, type PowerShell, and open Windows PowerShell or PowerShell. A normal window is enough for reading. You do not need "Run as administrator" for the commands in this article, and it is better not to use it, because an elevated window makes an accidental change possible.

Two habits make the work easier:

  • Run each command on its own and read the result before moving on.
  • Do it twice: once with the VPN disconnected and once with it connected. Comparing the two outputs is the fastest way to see what the VPN changed.

A useful trick is to save each output to a text file you can compare, for example with Get-NetRoute | Out-File before.txt in a folder you choose. Keep those files private, because routing tables can include addresses from your home or work networks.

Listing routes with Get-NetRoute

The main command is Get-NetRoute. On its own it prints every route, including IPv6, which can be long. Start by limiting it to IPv4:

Get-NetRoute -AddressFamily IPv4

The columns you will see are:

Column Meaning
ifIndex A number identifying the network interface the route belongs to
DestinationPrefix The range the rule covers, such as 192.168.1.0/24 or 0.0.0.0/0
NextHop The gateway for the packet; 0.0.0.0 usually means "directly connected"
RouteMetric The cost of this specific route
ifMetric The cost assigned to the interface itself
PolicyStore Whether the route is active or stored as a persistent setting

Windows adds the route metric and the interface metric together to get the effective cost. Lower is preferred. This is why a wired connection, which normally gets a low interface metric, tends to beat Wi-Fi when both offer a default route.

To focus on the catch-all rule only, filter by prefix:

Get-NetRoute -DestinationPrefix "0.0.0.0/0"

Read the result line by line. Each row is one default route, with its interface number and metric. If there is only one row and it belongs to the VPN adapter, the tunnel owns the catch-all. If there are two or more rows, the lowest combined metric wins, and you should look at which interface that is.

If your VPN works by adding two halves of the address space instead, you may see no 0.0.0.0/0 row for it but two rows for 0.0.0.0/1 and 128.0.0.0/1. Check for those too:

Get-NetRoute -AddressFamily IPv4 | Where-Object { $_.DestinationPrefix -in "0.0.0.0/1","128.0.0.0/1" }

Seeing both of those on the VPN adapter is a normal sign of a full-tunnel setup, and they win over the plain default route because they are more specific.

Matching interface numbers to adapter names

The ifIndex number means little until you map it to a name. Two commands help:

Get-NetAdapter

Get-NetIPInterface -AddressFamily IPv4 | Sort-Object InterfaceMetric

Get-NetAdapter lists adapters with their name, description, status and interface index. Look for the one that belongs to the VPN. Its name and description depend on the VPN software and Windows version, so recognise it by the fact that it appears when the VPN connects and disappears or shows as disconnected when it stops. Get-NetIPInterface shows the interface metric for each adapter, which explains why one network beats another.

For a combined view of what each adapter has, try:

Get-NetIPConfiguration

It prints each connected interface with its IP address, default gateway and DNS servers in one block. When the VPN is up, you should see the VPN adapter with its own address. Whether it lists a gateway depends on how the VPN is configured, so treat a missing gateway as a clue to investigate, not as proof of a fault.

Asking Windows which route it would use

Reading the table by eye is easy to get wrong, because several rules can match one address. The more reliable way is to ask Windows to run the selection for you:

Find-NetRoute -RemoteIPAddress 1.1.1.1

You can replace the address with any destination you care about, such as a server you are trying to reach. The output shows the interface, the source address Windows would use, the next hop and the route that matched. If the interface shown is the VPN adapter, that destination goes through the tunnel. If it is your Wi-Fi or Ethernet adapter, it does not.

This is the single most useful check for a split-tunneling question. Run it for a public address and again for a private address on your office or home network. A correct split setup sends the first one one way and the second another. If you want a deeper explanation of that design, read Windows VPN split tunneling.

A plain example: you connect the VPN, and a work server at 10.20.5.9 will not open while ordinary sites do. Running Find-NetRoute -RemoteIPAddress 10.20.5.9 shows the Wi-Fi adapter, not the VPN adapter. That tells you the traffic for that range is never entering the tunnel, so the issue is a missing or overridden route rather than a slow server. Private ranges like this are described in RFC 1918.

Comparing before and after connecting

A single snapshot is hard to judge. A before-and-after comparison removes the guesswork:

  1. Disconnect the VPN and run Get-NetRoute -DestinationPrefix "0.0.0.0/0". Note the interface number, next hop and metrics.
  2. Run Get-NetAdapter and note which adapters are up.
  3. Connect the VPN and wait until the app shows a connected state.
  4. Run the same two commands again.
  5. Compare: a new adapter should appear, and either the default route changes owner or new half-range routes appear.

If nothing changes at all, the VPN may not be fully connected, or it may be set up so that only certain destinations use it. If the default route changes but pages still do not load, routing may be fine and the cause may be somewhere else, such as DNS or packet size. In that case the guides on Windows VPN DNS leaks and the Help Center page on a connected VPN with no internet are better next steps.

You can also confirm the path with a trace:

Test-NetConnection -ComputerName example.com -TraceRoute

This lists the hops toward a destination. The first hop tells you which gateway your packets leave through: your home router's local address, or an address inside the VPN. Some networks do not answer trace probes, so a few missing lines are common and not an error.

Reading the output: a small worked example

Imagine the VPN is off and you run the default route filter. You see one row: ifIndex 12, 0.0.0.0/0, NextHop 192.168.1.1, RouteMetric 25, ifMetric 35. That is your Wi-Fi adapter reaching your home router.

You connect the VPN and run the command again. Now you see two rows with ifIndex 12 and a new ifIndex 21, and the new one uses a small next hop such as 10.8.0.1 with a low metric. The VPN adapter is now the more attractive path for the catch-all, and Find-NetRoute for a public address names ifIndex 21. That is what a full-tunnel connection normally looks like.

Now suppose the VPN adapter 21 appears, but Find-NetRoute for a public address still names ifIndex 12. The VPN is up as an adapter but not winning the default. Common reasons include a lower metric on the other connection, a second VPN or virtual adapter claiming the same role, or a split-tunnel setting. That points you to the next step: disconnect the extra network or adapter and test again.

These numbers are only an illustration. Your interface numbers, addresses and metrics will be different, and VPN software may name and configure its adapter in its own way.

Common patterns and what to try

What you see What it may mean Safe next step
Default route only on Wi-Fi or Ethernet while VPN shows connected VPN is split-tunnel, or tunnel is not carrying traffic Check app settings, reconnect, repeat the check
Two default routes with similar metrics Competing connections Disconnect the unused network, reconnect the VPN
VPN adapter present but no routes on it Connection not fully up Disconnect and reconnect, update the app
Private office range goes to Wi-Fi Missing route for that range Confirm the VPN is meant to reach that network
Routes look right but sites fail Cause may not be routing Check DNS, packet size and firewall
Many extra adapters listed Virtual machines or other tools Turn off unused virtual adapters temporarily

Work through the table one row at a time and test after each change. Changing several things at once makes it impossible to know what helped.

Limits and what to watch for

Routing checks are useful but narrow. A few points to keep in mind:

  • A correct routing table does not prove the VPN is protecting you. It shows where Windows sends packets, not what happens to them afterward. Other checks, such as comparing your public IP address and testing for DNS leaks, belong alongside it.
  • A VPN does not guarantee access to every site, and a site may still block or limit connections even when routing is perfect.
  • Routes can change at any moment when a network connects, disconnects or sleeps. A snapshot is only true for that moment, so repeat the check if the situation changes.
  • IPv6 has its own routing table. If you only look at IPv4, you can miss traffic that leaves over IPv6. Run Get-NetRoute -AddressFamily IPv6 and compare, and see Windows VPN and IPv6 for how the two protocols behave around a VPN.
  • Adding or deleting routes by hand is an advanced step. Manual routes often disappear after a reconnect or reboot, and a wrong entry can cut off your own connection. If you are not sure, leave the table alone and ask support, or use the app's own settings.
  • Work or school computers may have routes managed by an administrator. Do not change them. If something looks wrong, report it to the person who manages the device.

For a general overview of how VPNs work, Cloudflare Learning has a clear explainer, and Microsoft Support documents connecting to a VPN in Windows.

Summary

PowerShell gives you a clear, read-only view of how Windows routes your traffic. Get-NetRoute shows the table, Get-NetAdapter and Get-NetIPInterface name the interfaces and their metrics, and Find-NetRoute tells you which path a specific destination would take. Comparing the output before and after connecting shows what the VPN changed, and the default route plus the VPN adapter are the two things to check first. Treat the result as one clue among several, not as proof of safety. If you want a pass you can switch on for a fixed number of days and test these checks with, you can look at the options on the pricing page.

Frequently asked questions

Which PowerShell command shows my routing table?

Get-NetRoute lists the routing table on Windows. Add -AddressFamily IPv4 to limit it to IPv4 routes. The older route print command in Command Prompt or PowerShell shows similar information in a different layout.

Do I need administrator rights to read routes?

Usually not. Reading the routing table with Get-NetRoute works in a normal PowerShell window. Adding, changing or deleting routes needs an elevated window, and this article only uses read-only commands.

How do I know which route Windows will use for a destination?

Run Find-NetRoute -RemoteIPAddress followed by an address. It reports the interface, the source address and the route Windows would pick. This is more reliable than reading the whole table by eye.

What does it mean if the VPN adapter has no default route?

It can mean the VPN is set up for split tunneling, where only some destinations use the tunnel, or that the connection is not fully established. It is a clue rather than a verdict, so compare it with what the app shows and with your IP address check.

Can I fix a routing problem by deleting routes?

It is rarely the best first step. Manual changes usually vanish after a reconnect or reboot, and a wrong deletion can cut off your own connection. Disconnecting extra networks and reconnecting the VPN is the safer first move.

About the author

Bob Kanokphon Thongdee, founder of XPASS VPN

Bob Kanokphon Thongdee

  • Founder of XPASS VPN
  • Co-founder of eSIMonline.asia
  • More than 7 years in online marketing
  • Founder of Cojourney Visa and Cojourney Travel

Need a VPN for a short trip or a busy month?

XPASS sells prepaid passes for a set number of days. You pay once and nothing renews automatically.

See passes

Keep reading

Troubleshooting

How Do Multiple Default Routes Cause VPN Connection Problems?

When Wi-Fi, Ethernet, a hotspot and a VPN each claim to be the way to the internet, traffic can take the wrong path. Here is how to read your routes and untangle the clash.

11 min read

Troubleshooting

Fix Missing VPN Network Adapter on Windows

A VPN that cannot find its network adapter will not connect. This guide shows where Windows hides adapters, how to bring one back and when to reset.

10 min read

Device Guides

How to Set Up VPN Split Tunneling on Windows

A practical Windows walkthrough for windows vpn split tunneling: choose what skips the tunnel, apply it through your app or a Windows VPN profile, and prove it works.

10 min read