中文

Tutorials

v2rayN setup on Windows: import, route, troubleshoot

Getting v2rayN running: subscriptions, latency testing, system proxy, routing presets, and the proxy environment variables for tools that ignore all of it.

By MaoUpdated 2026-08-205 min read

v2rayN is the long-standing Windows client. Lighter than the Clash family, with more direct control over the core.

When to choose it

SituationPick
First proxy client everClash Verge Rev — friendlier
You want something lightweightv2rayN
You want to tune Xray/sing-box core parametersv2rayN
Your nodes are all vmess/vlessv2rayN, best native support
You want the mature Clash rule ecosystemClash Verge Rev

I keep both. Clash Verge Rev day to day, v2rayN when debugging node parameters — it exposes the per-node fields more completely, which makes them easier to correct.

Clash side: Clash Verge Rev setup.

Step 1: download

From the official v2rayN GitHub Releases page.

PreferenceFile
Simplestv2rayN-windows-64-desktop.zip — self-contained, no .NET install
SmallestTrimmed build, requires .NET Desktop Runtime

Extract it to a permanent folder. It writes its configuration alongside the executable, so moving it later loses your setup. Mine lives in D:\Tools\v2rayN\.

Step 2: add a subscription

  1. Menu → SubscriptionsSubscription settings
  2. Add
  3. Remarks: any name
  4. URL: your subscription link
  5. Confirm
  6. Menu → SubscriptionsUpdate subscriptions (without proxy)

The server list should fill.

Step 3: test and select

  1. Select all servers (Ctrl+A)
  2. Right-click → Test servers real delay

The distinction matters:

TestMeasuresUseful?
Ping delayICMP round trip to the IPLimited — many servers drop ICMP
Real delayA request through the nodeUse this
Speed testActual download rateMost accurate, slowest

Sort by delay, double-click one to make it active.

Discard timeouts, anything over 800 ms, and anything obviously wrong. Latency is only step one — full method in How to actually test a free node.

Step 4: system proxy

From the tray icon or the menu:

ModeMeaning
Do not change system proxyClient running, system ignoring it
Set system proxyDay to day
Global proxyEverything through the proxy
Clear system proxyOff

Step 5: routing

Menu → SettingsRouting settings.

v2rayN ships presets. Use the "bypass mainland" style preset — local traffic direct, foreign traffic proxied.

Global routing sends local requests abroad and back, which is slow for no reason.

Programs that ignore the system proxy

Same problem as every other client: games, Steam, Docker, Git and many command-line tools do not read the system proxy setting and go straight out the physical adapter.

Option 1: TUN mode

Recent v2rayN builds include it. It captures everything at the adapter level.

Caveats match the Clash side: administrator rights, possible antivirus conflicts, occasional route conflicts on machines with virtualisation installed.

Option 2: per-tool proxy settings

# Git
git config --global http.proxy http://127.0.0.1:10809
git config --global https.proxy http://127.0.0.1:10809

# npm
npm config set proxy http://127.0.0.1:10809
# Temporary, PowerShell
$env:HTTP_PROXY="http://127.0.0.1:10809"
$env:HTTPS_PROXY="http://127.0.0.1:10809"

Mind the port. v2rayN defaults to 10809 for HTTP and 10808 for SOCKS — different from Clash's 7890. Both are visible and editable under Settings → Parameter settings.

Common problems

Greyed-out nodes

Grey means untested or failed. Right-click → test real delay.

If everything fails:

  1. You may have no route out at all
  2. The subscription may be entirely dead → update it
  3. The core may not have started → View → View service log

Port already in use

Settings → Parameter settings → change the SOCKS and HTTP ports (20808/20809, say).

Update any other software where you entered the old port.

Hysteria2 will not connect

Check two things:

  1. The build is recent enough to support it
  2. The sing-box core is enabled in core settings

Hysteria2 runs over QUIC/UDP, and some networks restrict UDP entirely. If that is your situation, use a TCP-based protocol instead — see SS vs VMess vs Trojan vs Hysteria2.

Config changes not taking effect

v2rayN needs the core restarted. There is a Restart service menu item.

Where the logs are

View → View service log. Start here when something breaks — the answer is usually in it.

For more detail, set the log level to debug under Parameter settings.

Questions people keep asking

v2rayN or Clash Verge Rev?

Beginners are better served by Clash Verge Rev — the interface exposes logs and the connection list where you can see them. v2rayN is lighter and gives finer control over the core, which suits people who already know what they are doing. Both are free and open source; installing both is reasonable.

Does v2rayN support Hysteria2?

Recent versions do, through the bundled sing-box core. Older builds run only Xray/V2Ray and do not. If a Hysteria2 node will not connect, check your version and which core is selected before blaming the node.

My nodes are greyed out.

Grey usually means untested or failed test. Run "Test servers real delay". If everything fails, either the whole subscription is dead or you currently have no route out to refresh it with.

Do I need to install .NET?

Recent releases ship self-contained and need nothing extra. The trimmed builds require the matching .NET Desktop Runtime, and will tell you so on launch.

Written from my own testing. Conditions change; if something here has gone stale, email [email protected] and I will update it with a date.

Read next