What a proxy does for Anti-Captcha
Many sites tie a captcha token to the IP address that asked for it. If the service solves from its own address and you submit from yours, the token can be refused. Passing your proxy to the service makes both come from one address.
The right proxy type for Anti-Captcha
A residential proxy with a sticky session, with the same username used in the task and in your own client.
The values to enter in Anti-Captcha
Every PiratProxies plan comes down to four values: host, port, username and password. Here they are for Residential; your own username and password are on your plan page.
| Host | resi.piratproxies.com |
|---|---|
| HTTP port | 8080 |
| SOCKS5 port | 1080 |
| Username | USERNAME |
| Password | shown on your plan page |
There is no separate country or session field: both are part of the username. Your plan page has a generator that writes it, and Targeting and sessions describes each piece.
Setting it up in Anti-Captcha
- Pick the task type without
Proxylessin its name. - Add
proxyType,proxyAddress,proxyPort,proxyLoginandproxyPasswordto the task. - Also send the
userAgentyour own client uses, so the browser details match as well as the IP address. - Submit the token from your client through the same proxy.
Code: Anti-Captcha through a proxy
The proxy part of a task
curl -s https://api.anti-captcha.com/createTask -H "Content-Type: application/json" -d '{
"clientKey": "YOUR_API_KEY",
"task": {
"type": "RecaptchaV2Task",
"websiteURL": "https://example.com/login",
"websiteKey": "SITE_KEY",
"proxyType": "http",
"proxyAddress": "resi.piratproxies.com",
"proxyPort": 8080,
"proxyLogin": "USERNAME-country-us-time-600-session-a1b2c3d4",
"proxyPassword": "PASSWORD"
}
}'Put your own login from the plan page in place of USERNAME and PASSWORD. The example calls an IP-check service, so what it prints is the address your request came from.
Should Anti-Captcha rotate IPs or keep one?
Use a sticky session and hand Anti-Captcha the very same username your own requests use: the session ID in it is what puts both on one IP address. If the username rotates, the token gets solved from one address and submitted from another, and sites that compare the two will refuse it.
Here is what a sticky username looks like:
USERNAME-country-us-time-600-session-a1b2c3d4When Anti-Captcha will not connect
proxyAddressis the host on its own, withouthttp://and without the port.- The session in the username has a time limit. Solve and submit within it, or the IP address will have changed in between.
- Error
407means the login was refused. Copy the username and password from your plan page once more, and make sure no space crept in and the username was not cut short. - An IP in the wrong country nearly always comes from the username, since the country code lives there. Other fixes.
Anti-Captcha and proxies: questions
Which PiratProxies plan suits Anti-Captcha best?
A residential proxy with a sticky session, with the same username used in the task and in your own client.
Words used in this guide: captcha, captcha solver, sticky session, ip reputation.
Anti-Captcha belongs to its own developers, and PiratProxies has no connection with them; we name it only to say what this guide covers. Follow the rules of the sites you visit and our acceptable use policy.