Integrations · Automation & scraping
Use HProxy with cURL.
Test an HProxy proxy from the command line before you wire it into anything.
cURL is the command-line HTTP client that ships on almost every system, the fastest way to confirm a proxy works.
Before debugging a scraper, prove the proxy itself is good. One cURL call through it, checking the IP it returns, separates a proxy problem from a code problem.
Setting up HProxy in cURL
- 1.Take your host, port and login from the dashboard.
- 2.Pass the proxy with -x and the login with -U.
- 3.Hit an IP-echo endpoint and confirm the address and country come back as expected.
curl -x res.hproxy.com:8080 \
-U "user-country-us:pass" \
https://ipinfo.io/jsonWorth knowing
If this returns the right country but your tool does not, the problem is in the tool's config, not the proxy.
Frequently asked questions
How do I test a proxy from the command line?
Send one request through it to an endpoint that echoes back the address it saw, and read what comes back. That single command settles the question everything else depends on: whether the proxy works at all, and which exit address and country you actually got. Do this before debugging anything in your application.
cURL works but my scraper does not, what now?
Then the proxy is fine and the problem is in the tool's configuration, which is exactly why this test is worth running first. Check that your client sets the proxy for the right scheme, that credentials are being sent, and that nothing is silently falling back to a direct connection for HTTPS.
How do I see the headers a proxy is adding?
Request an endpoint that echoes the headers it received and read them. Your own address appearing anywhere means the proxy is transparent; Via or X-Forwarded-For present without your address means anonymous; none of them present means elite. That is the anonymity grade measured rather than assumed.
Why does cURL fail with an SSL error through a proxy?
Usually because something is intercepting the connection rather than tunnelling it, which is normal on a corporate network running its own inspection proxy and abnormal otherwise. Disabling verification makes the error vanish and hides the reason, so it is worth understanding the cause before reaching for that flag.
How do I use SOCKS5 with cURL?
There is a dedicated option for SOCKS proxies, separate from the general proxy option, and a variant that resolves hostnames at the proxy instead of locally. Prefer the remote-resolving form, because the local one produces a DNS leak that shows your own resolver every destination you visit.
The host, port and login shown here are the format; your exact values are on your dashboard, ready to copy.