Define which stage is slow
A proxy request can be delayed during gateway resolution, connection, upstream negotiation, destination TLS, destination processing, or response download. One latency number hides these stages. Record the destination, protocol, request size, client location, concurrency, and measurement window before comparing results.
curl's time_connect measures time from the start until TCP connection completes. With a proxy, that usually means the connection to the proxy rather than a ready end-to-end path. time_appconnect measures cumulative time until TLS or another application handshake completes. time_starttransfer includes previous preparation and the wait for the first byte; time_total covers the entire operation. These are milestones, not four independent durations to add together.
Establish a controlled baseline
Choose a small HTTPS endpoint that you own or have permission to test, with a fixed response size. Compare direct access and a confirmed proxy path with similar location, protocol, concurrency, and timing. Comparing local direct access to one large website with a remote proxy accessing a different business endpoint cannot isolate the proxy's contribution.
This Bash example contains no live credentials. example.test is for your own test environment, not a publicly reachable health-check destination. Provide authentication through controlled client configuration.
curl --proxy http://proxy.example.test:8080 --connect-timeout 5 --max-time 15 --silent --show-error --output /dev/null --write-out 'tcp=%{time_connect} tls=%{time_appconnect} first=%{time_starttransfer} total=%{time_total}\n' https://target.example.test/health
Narrow the cause in steps
- Establish whether the request succeeded. Group authentication failures, destination refusals, and timeouts; do not silently remove them from statistics.
- If TCP time increases, inspect the route to the gateway, its name resolution, and entry load before changing destination settings.
- If TCP is stable but TLS or first-byte time rises, investigate the upstream path, handshake, and destination response. Subtracting timestamps gives only approximate stage estimates under controlled conditions without redirects or connection reuse.
- Repeat at a fixed low concurrency. Report sample count, median, tail behavior, and failures. One extreme value is not average experience, and a tiny sample does not support precise percentile claims.
Preserve the measurement limits
Reused connections skip preparation. Redirects and retries change the measured operation. Observe cold and reused connections separately, recording compression, the side performing DNS resolution, and retries. Do not retry indefinitely until you obtain a flattering result, or disable TLS verification to reduce apparent duration.
A successful HTTP probe proves only that its observation point could request that URL. It does not establish a particular supplier exit or the number of addresses online in a region. Interpret HBridg status and review information with its source, path, and time window. Fields lacking measurement evidence remain unknown, and demo samples are not procurement rankings.
Sources
This original troubleshooting guide draws topic inspiration from Proxyway Guides, without performance figures. Definitions are documented in curl write-out variables, tunnel behavior in curl HTTP proxies, and retry behavior in curl retry.