v2rayN Connection Timeout: How to Diagnose Failed Speed Tests and Handshake Errors

Troubleshoot v2rayN timeouts step by step: check your system clock, ports and firewall, subscription, transport settings, TLS, and SNI.

At a glance

For v2rayN users dealing with a single timed-out node, failed speed tests across a group, or connection problems after updating a subscription. Keep test conditions consistent, then narrow the issue down to your device, the node endpoint, the handshake, or the test target. Change one setting at a time and save logs before and after each change so a temporary fix isn’t mistaken for a confirmed solution.

First, identify the type of speed test failure

The latency shown in the node list is not the same as download speed. A TCP latency test checks whether a TCP connection can be made to a specified address and port. A real connection test also tries to reach a test target through the node. Passing the first test only confirms that the endpoint accepts a TCP connection; it does not verify authentication, the transport handshake, or access to the target site. Conversely, an unreachable test target can make a working node time out during a real connection test.

DNS resolutionEndpoint connectionTransport handshakeTarget requestResponse received

Check your system clock, then run a comparison test

Certificate validity checks depend on the system clock, and VMess authentication is sensitive to clock differences between the client and server. A clock that looks right on your desktop doesn’t guarantee the date, time zone, and actual time are correct. Check the clock first, especially after switching operating systems, leaving a device asleep for a long time, or changing the date manually. Then investigate any certificate errors.

  1. Sync your system clock

    In Windows 11, open Settings → Time & language → Date & time. Check your time zone, turn on Set time automatically, then select Sync now under Additional settings. If syncing fails, make sure Windows can reach its time service.

  2. Record the test conditions

    Note the v2rayN and core versions, the node alias, and the test time. Use the same network and test method, and test one failed node at a time to keep logs from multiple tests separate.

  3. Find the first error

    Use the test time to locate the relevant log entry. Look for the most specific error in the chain, such as a DNS resolution failure, a refused connection, or an expired certificate. The final timeout message is often just a consequence of an earlier failure.

Check the remote port and your local firewall

The remote port comes from the node configuration, such as TCP 443. The local proxy port comes from v2rayN’s listener settings, such as 10808. These are examples, not interchangeable values. If your browser can’t connect to the local port, check that the core is listening and that the port isn’t in use. If the remote port is unreachable, investigate the node address, your current network, and the remote listener.

For a node confirmed to use TCP, run this command in Windows PowerShell. Replace the example hostname and port with an authorized node endpoint; don’t enter your local proxy port. If the node uses UDP transport, this TCP test won’t tell you whether UDP is reachable.

Test-NetConnection -ComputerName node.example.net -Port 443
ResultWhat it tells youNext step
TcpTestSucceeded : TrueTCP connection established for this testCheck the subscription, transport, and handshake next. This result alone doesn’t mean the node is ready to use.
TcpTestSucceeded : False, but a remote address is listedTCP connection not established for this testCheck the remote address and port in the output, then inspect local outbound rules or ask an administrator to check the remote listener.
The node hostname didn’t resolve to an addressThe test never reached the port connection stageCheck the hostname spelling and your local DNS. Don’t use this result to conclude that a firewall is blocking the connection.

Narrow down the problem with a comparison test

If the same endpoint works on another authorized network but not on your current network, record the resolved addresses and test times for both attempts, then ask your network administrator to check the relevant outbound rules. Don’t disable the entire firewall to test a hunch.

Tell a failed subscription update from an invalid node configuration

A subscription URL retrieves a list of nodes; it isn’t a connection endpoint. If an update fails, v2rayN may still show previously saved nodes. A successful update only confirms that a list was retrieved; it doesn’t prove that your account is still valid or that every node is online. If a timeout occurs after an update, make sure you’re testing the updated entry—not an older node with the same name in another group.

Check transport settings, TLS, and SNI

Once the port is reachable and the subscription details check out, open the node editor. Compare its settings with the configuration provided by your service provider; don’t guess by trying random values. The node address determines where the connection goes. With standard TLS, the server name is used for SNI during the handshake and for certificate name verification. Even if the address is an IP, don’t replace the provider’s specified server name with that IP. The WebSocket request Host is an HTTP-layer field and can differ from the TLS server name.

connect: connection refused

Cause and fix: The TCP connection to the specified address and port was actively refused. Check whether the log refers to a local address or the remote endpoint, then verify the local core listener or the remote port configuration, respectively.

x509: certificate has expired or is not yet valid

Cause and fix: The certificate’s validity period didn’t include the time of verification. Sync your system clock first. If the time is correct, ask the provider to check the certificate’s validity and the certificate actually served by the endpoint.

websocket: bad handshake

Cause and fix: The remote server didn’t return the expected WebSocket upgrade response. Check the path and Host, and note the HTTP status code in the logs. If the response is 404, ask the provider to check the route.

context deadline exceeded

Cause and fix: The operation didn’t finish before the deadline. This line alone doesn’t show which stage stalled. Check the logs around the same test, then use the port test and handshake errors to narrow it down.

Retest and report the issue

After changing each field, retest using the original network, node, and test method. If the real connection test still fails but the log has changed from a TCP timeout to a certificate error, troubleshooting has reached the handshake stage; there’s no need to go back and change the port again. Don’t bypass certificate verification just to get a successful test. Fix the server name, trust chain, or server configuration instead.

Download v2rayN