System proxy settings determine whether apps configured to use them send requests to the local proxy. Routing modes determine which outbound connection handles requests after they reach the core. For everyday use, start with “Set system proxy + Bypass China,” then check the logs to confirm which rules matched. Use Global to route traffic through one proxy exit or troubleshoot routing, and Direct to test your local network. This guide also covers port checks, command-line tests, and how to verify changes.
System Proxy and Routing Modes: Understand the Entry and Exit
v2rayN is a desktop client for managing nodes, launching the proxy core, and adjusting related settings. The system proxy is neither a node nor a routing rule: it tells apps configured to use the system proxy which local address to send requests to. Once the core receives a request, routing rules determine whether it uses a proxy outbound, a direct outbound, or a blocked outbound.
So “Why is an app still connecting directly when Global is selected?” is not a contradiction. If the app ignores the system proxy, has no local proxy configured, and is not captured by another traffic-redirection mechanism, its connections never reach the core. Routing rules cannot handle requests that never enter the proxy.
- Application: Browsers, command-line tools, and other apps decide whether to use the system proxy and may have their own proxy settings.
- Local entry point: The request reaches a local HTTP, SOCKS, or mixed-protocol listening port, where the core receives it.
- Routing decision: Rules are checked in order against criteria such as domain, destination IP, and port.
- Outbound connection: The selected node connects to the destination, or the local network connects to it directly.
Global, Bypass China, and Direct: Choosing a Routing Mode
Mode names describe sets of routing rules, not guaranteed network behavior. Different v2rayN interfaces and custom rule sets may use different names. The actual behavior depends on the current rule order, matching criteria, and default outbound. In particular, “Bypass China” does not mean every site is classified by its geographic location in real time.
Bypass China
RecommendedCommon rule sets send domains classified as mainland China, destination IPs in mainland China, and local network addresses through a direct connection; other requests go through the proxy. Domain and IP classifications rely on rule data. With CDNs, unlisted domains, or changing DNS results, check the logs to confirm which outbound was used.
Best for: Everyday browsing across sites in mainland China and elsewhere
Global Proxy Routing
Typically sends requests that are not handled by earlier exception rules through a proxy node. Useful for checking whether routing rules are misclassifying traffic, but it does not mean every app uses the proxy or that LAN and DNS traffic necessarily take the same route.
Best for: Using a single proxy exit or temporarily testing routing rules
Direct Routing
Requests that reach the core typically connect to their destinations through the direct outbound, without being relayed through a remote node. The local listener can remain active, making this useful for checking whether your local network can reach a destination while leaving app proxy settings unchanged.
Best for: Testing your local network when you need to connect directly to a destination
Troubleshooting Order: Confirm Traffic Capture Before Comparing Routes
First make sure the same request reaches the local listening port, then test it with Bypass China and Global. Only prioritize checking routing rules if the first test fails, the second succeeds, and the logs show a change in outbound. Do not change the node, port, and DNS settings at the same time.
v2rayN Setup: Configure the Entry Point and Route Separately
Start the client and select an existing working node, then check the local listener. On Windows, the usual controls are “System Proxy” and “Routing” in the right-click menu for the taskbar tray icon; the desktop interface may also provide corresponding selectors. Menu locations and system permission prompts may differ on macOS, so do not follow the Windows tray instructions as-is.
- Check the listener: Open “Settings” → “Parameter Settings” and look for local listening port or inbound options. Note the current port and protocol. Option locations may vary between interfaces, so follow the labels in the current version.
- Configure the entry point: In the “System Proxy” menu, select “Set system proxy” or the equivalent option in your interface so apps that use the system proxy send traffic to the local listener.
- Choose a route: In the “Routing” selector, choose the Bypass China rule set. If you imported a custom rule set, first confirm its default outbound and private address rules.
- Start a new connection: After applying the settings, revisit the destination. If needed, close the existing page connection or restart the test app to avoid results being affected by connection reuse.
- Check the logs: Confirm the core is running and the listener started successfully, then check which outbound handled the destination request. If the current log level does not show access records, temporarily enable the relevant access log and turn it off again after testing.
“Clear system proxy” only removes the system-level proxy setting. It does not remove proxy settings in browser extensions, terminal environment variables, or disable TUN. “Do not change system proxy” usually means the client leaves the current setting untouched; it does not prove that the proxy is off.
| Combination | Apps that use the system proxy | What to check |
|---|---|---|
| Set system proxy + Bypass China | Requests enter the core, then follow routing rules | Rule data and DNS results can affect which rules match |
| Set system proxy + Global | Requests usually use a proxy node after entering the core | Earlier exception rules may still send traffic direct or block it |
| Set system proxy + Direct | Requests connect directly from your local machine after entering the core | Does not shut down the local proxy service |
| Clear system proxy + any routing mode | Apps no longer use the system setting to connect | Check manual proxy settings, environment variables, and TUN separately |
Local Ports and Command-Line Tests: Check Whether Requests Reach the Core
The examples below use these specific values: HTTP listener 127.0.0.1:10809 and SOCKS listener 127.0.0.1:10808. These are not default values for every version; some configurations use a single mixed-protocol port. Before running a command, replace the port with the one actually enabled in Parameter Settings. Do not send an HTTP request to a port that only supports SOCKS.
On Windows, run curl.exe in a terminal to avoid parameter parsing issues caused by a same-named alias in some PowerShell environments. The two commands below explicitly specify a proxy, so they do not depend on whether the system proxy is enabled. The example destination checks an HTTP response; one successful request does not prove that every site and protocol is working.
curl.exe --proxy http://127.0.0.1:10809 --connect-timeout 5 --max-time 15 -I https://example.com/
curl.exe --proxy socks5h://127.0.0.1:10808 --connect-timeout 5 --max-time 15 -I https://example.com/
In a macOS terminal, use curl as the command name. In the second command, socks5h means the proxy resolves the destination domain instead of curl resolving it locally to an IP address first. This affects the destination information received by the core and may also affect domain-based rule matching. Note which proxy protocol you use so the two DNS resolution paths are not confused.
- Connection to the local port is refused: First check that the core is running, the port is correct, and the listener supports the protocol you are using. Node connectivity has not yet been tested.
- Local connection succeeds but the remote request times out: Check the node connection, destination connection, and DNS in the logs. Do not assume the subscription has expired.
- The command succeeds but the browser fails: First check the browser's own proxy settings, extensions, and existing connections, and confirm whether it uses the same entry point.
Bypass China Rule Limitations: Domains, IPs, and DNS
Common V2Ray and Xray routing setups use geosite:cn to classify domains and geoip:cn to classify IP addresses. These rely on the corresponding rule data; the core does not determine geographic location on its own. A domain classified as mainland China does not mean its server will always resolve to the same region. Likewise, an IP address associated with a region does not mean every service on a site should use the same outbound.
The snippet below illustrates how matching works; it is not a complete, runnable client configuration. direct must correspond to an existing direct outbound tag. Whether unmatched requests use the proxy also depends on the other rules and the default outbound. Do not overwrite the runtime configuration generated by v2rayN. Adjust the corresponding rules in the client's routing settings instead.
{
"routing": {
"domainStrategy": "AsIs",
"rules": [
{
"type": "field",
"ip": ["geoip:private"],
"outboundTag": "direct"
},
{
"type": "field",
"domain": ["geosite:cn"],
"outboundTag": "direct"
},
{
"type": "field",
"ip": ["geoip:cn"],
"outboundTag": "direct"
}
]
}
}
- Rule order: The first matching rule is used. If a broad proxy rule appears before the mainland China direct rules, the later rules may never match.
- Domain resolution strategy:
AsIsdoes not proactively resolve a domain to an IP address for IP rule matching. If a request contains only a domain and does not match a domain rule, do not assume a later mainland China IP rule will apply. - Private addresses: Local printers, router admin pages, and intranet services typically need a direct route. Corporate internal domains may also rely on dedicated DNS or a specific network connection.
- Updating rules: After changing DNS or rule data, establish a new connection to the same destination and check the logs. This helps avoid misdiagnosis caused by stale caches or long-lived connections.
Common Proxy Mode Questions: Troubleshoot by Symptom
Global is selected. Why is my terminal still bypassing the proxy?
Some command-line tools do not use the system proxy. First, use the command above with --proxy to specify the actual listening port. If it works, configure the proxy option or environment variable as described in the tool's documentation. Do not assume the terminal uses the proxy just because the client shows “Global.”
A site fails with Bypass China but works with Global. Should I switch nodes?
Keep the same node and compare the outbound records for the same destination in both modes. If Bypass China uses a direct connection while Global uses the proxy, check the domain and IP classifications and any earlier custom rules. If needed, add a specific rule for the destination and place it before broader rules.
Why does a browser still use the proxy after I clear the system proxy?
Check browser extensions, separate proxy settings, and whether TUN is enabled, then quit and reopen the browser to establish a new connection. Clearing the system proxy does not remove these separate settings or terminate existing connections.
What if router admin pages or company intranet sites stop working in Global mode?
First confirm that LAN addresses and internal domains have direct rules, and check rule priority. Then review the system proxy bypass list and internal DNS. Changing IP rules alone will not fix every internal domain resolution issue. Restore your usual work network settings after testing.
Keep Test Conditions Reproducible
Change one setting at a time and record the destination domain, local port, routing mode, and outbound tag in the logs. When troubleshooting is complete, switch from temporary Global mode back to your usual rules. Confirm a new connection works for a site in mainland China, a destination outside mainland China, and a LAN service.