Proxy errors
Proxy connection timed out
Nothing replied before the deadline. Work out whether the hostname resolves, the port opens, and the target itself is slow, in that order.
A timeout means nothing answered. No status code came back at all, which points at the network path, the hostname or the port rather than at credentials or content.
- Error
- Connection timed out
- Comes from
- Varies, see below
A timeout is the absence of an answer
Every other error in this family involves someone responding to you. A 407 is the proxy refusing credentials, a 403 is the site refusing the request, a 429 is the site asking you to slow down. A timeout is silence.
That silence can happen at three different stages, and conflating them is why timeouts are frustrating to debug. The hostname might not resolve. The hostname might resolve but the port never opens. Or the connection might succeed and the target site then take too long to respond.
Each has a different fix, and you can tell them apart in under a minute.
Stage one: does the hostname resolve?
If the proxy hostname does not exist in DNS, nothing else can work. This is worth checking first because it takes two seconds and produces an unambiguous answer.
NXDOMAIN means the name does not exist. That is not something you can fix from your side: either the hostname is wrong, or it has not been published. Check it against the exact value on your order, and if it matches, the provider needs to fix it.
dig +short proxy.example.com
# an IP address means resolution works
dig proxy.example.com | grep -i status
# status: NXDOMAIN means the hostname does not existStage two: does the port open?
A hostname that resolves can still be unreachable. The usual causes are the wrong port, a firewall between you and the proxy, or the proxy service not running.
Test the port directly, without involving HTTP at all. If this hangs, the problem is below the application layer and no amount of changing headers or credentials will help.
nc -vz proxy.example.com 8000
# or, without netcat:
timeout 10 bash -c 'cat < /dev/null > /dev/tcp/proxy.example.com/8000' && echo open || echo closedStage three: is the target slow?
If the proxy is reachable but requests still time out, the delay may be beyond the proxy. Separating connection time from total time tells you where it is going.
A small connect time with a large total time means the proxy is fine and the destination is slow. A large connect time means the problem is between you and the proxy.
curl -sS -o /dev/null \
-w 'dns: %{time_namelookup}s connect: %{time_connect}s total: %{time_total}s\n' \
--proxy proxy.example.com:8000 --proxy-user 'USER:PASS' \
--max-time 30 https://example.comCommon causes once you know the stage
Corporate and university networks frequently block outbound traffic on non-standard ports, which produces a clean timeout at stage two. Testing from a different network, such as a phone hotspot, separates this from a problem with the proxy in about a minute.
Timeouts that appear only under load are usually your own concurrency. Opening hundreds of simultaneous connections through one proxy will queue, and the queue surfaces as timeouts rather than as an error.
Residential and mobile addresses are genuinely slower than datacenter ones, because the traffic traverses a real consumer connection. A timeout that only appears on residential proxies may simply need a longer deadline rather than a fix.
What latency to expect from each proxy type
A timeout is a judgement about how long is too long, so the deadline has to match the route. Datacenter addresses sit in well-connected facilities and usually answer in tens of milliseconds. ISP addresses are registered to consumer providers but hosted in datacenters, so they behave similarly with a small penalty.
Residential and mobile traffic is different in kind. The request travels over a real home or carrier connection, which may be congested, metered or on a slow uplink. Several hundred milliseconds is normal and seconds are not unusual. A ten second deadline that is generous for datacenter traffic will fail constantly on mobile.
Set the timeout per proxy type rather than globally. Treating a slow residential route as a failure, retrying it, and then treating the retry as a failure too is a good way to multiply your bandwidth bill without ever completing the request.
Timeouts that only appear at scale
A proxy that responds instantly in a single test and times out under load is almost always a concurrency problem rather than a fault. Each proxy has a finite number of simultaneous connections it will handle, and requests beyond that queue rather than fail cleanly. From your side the queue is indistinguishable from a slow network.
The test is to reduce concurrency sharply, to two or three simultaneous requests, and see whether the timeouts disappear. If they do, the fix is either fewer parallel requests per address or more addresses to spread them across, and no change to the timeout value will help.
Frequently asked questions
Is a timeout the proxy's fault?
Not necessarily. It can be DNS, a blocked port, your own concurrency, or a slow destination. The three-stage test separates them.
What timeout should I set?
Datacenter proxies are usually fine with 10 to 15 seconds. Residential and mobile need 30 or more because the path is genuinely slower.
Why does it work from home but not from the office?
Many corporate networks block outbound traffic on non-standard ports. Test from a phone hotspot to confirm.
What does NXDOMAIN mean here?
The proxy hostname does not exist in DNS. Check it matches your order exactly; if it does, the provider has to publish it.
Ready to try it?
Create an account, add funds from US$1 and pick your country and proxy type.