Pcornel
Browse topics
Options
Recent
Favorites
Windows · Technical reference

Interface Metrics

Direct answer

Interface metrics rank network interfaces so Windows prefers the lowest-cost one, for example wired over Wi-Fi. Automatic metric uses link speed; set a fixed value with Set-NetIPInterface -InterfaceMetric.

When to use this

Use this when Windows prefers the wrong adapter.

First 30 seconds

1. Get-NetIPInterface | Sort InterfaceMetric.

2. Automatic metric based on speed.

3. Set: Set-NetIPInterface -InterfaceAlias <if> -InterfaceMetric 10.

4. Affects default route choice and DNS server order.

5. Verify with Find-NetRoute.

Operational verification

interface metric + route metric → lowest total wins

Context & applicabilityCommon mistakes · platform/version boundaries
Platform / version applicability
Windows networking and network services
applies
Structured applicability is explicit Topic metadata; it does not infer compatibility beyond the stored rows.
At a glance

Operational reference

Fast context before you go deeper.

PlatformWindows networking and network services
Scope / prerequisiteUse this when Windows prefers the wrong adapter.
What next?3 suggested next steps
Evidence1
On this pageJump to a specific section
Operational workflow

Verification & Troubleshooting

Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.

1 steps Observe → verify → isolate → change minimally → repeat the original test.
ObservedRecord what the original test actually shows

Capture the concrete output, symptom, packet, log or counter before changing anything.

Step 1 Common mistakes Narrow the fault
  • Manual metrics breaking VPN or failover routing.
Evidence references

Evidence · 1 on this Topic

Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.

observation · 1
Key points
  • The interface with the lowest metric is preferred.
  • Automatic metric is based on link speed.
  • A fixed metric overrides the automatic one.
Key checks
  • Get-NetIPConfiguration — addresses, gateway and DNS per interface
  • Get-NetAdapter — adapters, status and link speed
  • Get-NetRoute -AddressFamily IPv4 — routes and metrics
  • Test-NetConnection <host> -Port <p> — ping, route and TCP port test
  • ipconfig /all — full IP configuration
  • Get-NetIPInterface | Select InterfaceAlias,AddressFamily,Dhcp,InterfaceMetric — DHCP state and metric per interface
ReferenceHow it works1 section · depth on demand

In depth

Interface metrics influence which interface Windows prefers when routes are otherwise equal. Automatic metric derives from link speed: faster links get lower metrics, so wired usually beats Wi-Fi.

Get-NetIPInterface -AddressFamily IPv4 | Sort InterfaceMetric | ft InterfaceAlias,InterfaceMetric,AutomaticMetric
Set-NetIPInterface -InterfaceAlias VPN -InterfaceMetric 5
Set-NetIPInterface -InterfaceAlias Ethernet -AutomaticMetric Enabled

Interface metric also affects DNS server preference: Windows queries the DNS servers of the interface with the lowest metric first — a classic VPN split-DNS problem.

ReferenceImportant terms & boundaries1 section · depth on demand

How metrics are chosen

Windows adds the interface metric to the route metric. With automatic metric, faster links get lower values (e.g. ~25 for 1 Gb, lower for 10 Gb). Wired is usually preferred over Wi-Fi this way. VPN clients often set a low metric on their adapter so traffic uses the tunnel. Check the effective result with Find-NetRoute -RemoteIPAddress 8.8.8.8.

Source basisSource attribution states what this section is based on; it is not independent proof that the current environment matches it.
ReferenceConfiguration & state1 section · depth on demand

Commands

Get-NetIPInterface | Sort-Object InterfaceMetric | Format-Table ifIndex,InterfaceAlias,AddressFamily,InterfaceMetric,AutomaticMetric
Set-NetIPInterface -InterfaceAlias "Ethernet" -InterfaceMetric 10
Set-NetIPInterface -InterfaceAlias "Ethernet" -AutomaticMetric Enabled

Documented example, not captured output. Automatic metric by speed (examples): ≥ 2 Gb/s → 15, 1 Gb/s → 25, 100 Mb/s → 35. A lower metric wins. VPN adapters often get a low metric, pulling traffic and DNS queries into the tunnel.

Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Technical verification history

Verification history & basis

When and against what this Topic was checked. Later text edits do not count as a new check.

2026-09-14 · vendor docWindows networking and network services current

Authoritative/upstream documentation reviewed for bounded claims in IP Configuration → Interface Metrics. Documentation verification only; this is not observed lab or production Evidence.

Basis: https://learn.microsoft.com/en-us/windows-server/networking/ · confidence 94%
Confirmation

Confirm action

Continue?