HighProxies and CaptchaAI integration
How to Configure HTTP and SOCKS5 Proxies with CaptchaAI
Quick answer: CaptchaAI accepts an authenticated proxy in the format USERNAME:PASSWORD@IP:PORT. Use proxytype=HTTP for a HighProxies HTTP/HTTPS private proxy or proxytype=SOCKS5 for a HighProxies SOCKS5 proxy.
A proxy helps preserve the same public IP address between the application that loads a CAPTCHA, CaptchaAI while it solves the challenge, and the session that submits the returned token.
The API key and proxy credentials in this guide are test values. Use the API key from your own CaptchaAI account and the proxy IP, port, username and password assigned to your own HighProxies service.
Exclusive CaptchaAI Offer for HighProxies Users
HighProxies users can receive up to 15% off CaptchaAI through the dedicated partner landing page. CaptchaAI does not use a traditional promotional code for this offer; the available discount is applied through the landing page.
Get Up to 15% Off
Open the dedicated HighProxies offer page to view the CaptchaAI discount available to you.
Claim 50 Free Threads for 1 Day
Send HighProxies50 to @AskCaptchaAI on Telegram to request the special HighProxies trial.
Affiliate disclosure: HighProxies may earn a commission when you visit CaptchaAI or purchase through our partner links, at no additional cost to you. Offers are provided by CaptchaAI and may be subject to its terms and availability.
Why Use a Proxy with CaptchaAI?
Many CAPTCHA tasks can be solved without a proxy. A proxy becomes important when the protected website associates the challenge with the public IP address that loaded the page.
Preserve IP consistency
The application, CaptchaAI solver and token-submission session can use the same public proxy IP for the complete transaction.
Preserve location
A dedicated static proxy keeps the selected datacenter location consistent while the challenge is loaded, solved and submitted.
Do not add a proxy to every task automatically. CaptchaAI recommends omitting the proxy when the target does not enforce IP matching because an unnecessary proxy adds latency and another possible failure point.
CaptchaAI Proxy Support and Limitations
- Proxy usage is disabled by default. Ask CaptchaAI support to enable it for your account.
- Supported proxy types are
HTTP,HTTPS,SOCKS4andSOCKS5. - Authentication can use an authorized source IP or username/password credentials.
- CaptchaAI's general proxy guide explicitly supports reCAPTCHA v2.
- CaptchaAI does not support proxies with reCAPTCHA v3 because they significantly reduce its success rate.
- Individual task types can have additional requirements. CaptchaAI requires a proxy for its full-page Cloudflare Challenge method.
Use the documentation for the exact CAPTCHA method. An embedded Cloudflare Turnstile widget and a full-page Cloudflare Challenge are different tasks.
HTTP/HTTPS vs SOCKS5 Proxy Configuration
HighProxies provides dedicated static datacenter IPv4 proxies. It does not sell residential, ISP or mobile proxies.
| Setting | HTTP/HTTPS private proxy | SOCKS5 proxy |
|---|---|---|
| CaptchaAI proxy type | HTTP | SOCKS5 |
| Typical use | Websites, API clients and browser automation | Compatible TCP applications and browser automation |
| HTTPS destinations | Supported through the HTTP CONNECT method | Supported by compatible SOCKS5 clients |
| Local cURL test | http:// | socks5h:// for proxy-side DNS |
| HighProxies product | Private Proxies | Premium SOCKS5 Proxies |
Why use proxytype=HTTP for an HTTPS page? An HTTP proxy carries HTTPS traffic through the CONNECT method. The destination uses HTTPS, but the proxy endpoint remains an HTTP proxy.
Test Configuration Used in This Guide
CaptchaAI expects authenticated proxies in the format USERNAME:PASSWORD@IP_ADDRESS:PORT. Supply the protocol separately through proxytype. Do not include http:// or socks5:// inside CaptchaAI's proxy parameter.
Use your own account details: the API key and proxy credentials below are test values used only to demonstrate the integration. Clients must use the API key from their own CaptchaAI account and the credentials displayed for their own HighProxies service.
CaptchaAI API key placeholder
YOUR_CAPTCHAAI_API_KEY
HTTP/HTTPS test proxy
Host: 154.21.34.42
Port: 21298
Username: testuser1
Password: testpassword
CaptchaAI type: HTTP
testuser1:testpassword@154.21.34.42:21298
SOCKS5 test proxy
Host: 213.139.196.104
Port: 31290
Username: testuser1
Password: testpassword
CaptchaAI type: SOCKS5
testuser1:testpassword@213.139.196.104:31290
Test Both Proxies Before Using CaptchaAI
Confirm that each proxy accepts the credentials and can reach an HTTPS destination before sending a CAPTCHA task.
Test the HTTP proxy
curl --max-time 20 \
--proxy 'http://testuser1:testpassword@154.21.34.42:21298' \
'https://api.ipify.org'
Test the SOCKS5 proxy with proxy-side DNS
curl --max-time 20 \
--proxy 'socks5h://testuser1:testpassword@213.139.196.104:31290' \
'https://api.ipify.org'
The first command should return the HTTP service's public egress IP. The second should return the SOCKS5 service's public egress IP. The socks5h:// notation instructs cURL to resolve the destination hostname through the SOCKS5 proxy.
If a test fails
Check the host, port, username, password, copied whitespace, service status and whether the destination accepts the proxy IP. Correct the proxy connection before involving CaptchaAI.
Submit a reCAPTCHA v2 Task Through CaptchaAI
The examples use CaptchaAI's in.php endpoint and a public Google reCAPTCHA demonstration page. Replace the API key, site key, page URL and proxy credentials with the values for your own account and authorized target page.
HTTP proxy request
curl --request POST 'https://ocr.captchaai.com/in.php' \
--data-urlencode 'key=YOUR_CAPTCHAAI_API_KEY' \
--data-urlencode 'method=userrecaptcha' \
--data-urlencode 'googlekey=6Le-wvkSAAAAAPBMRTvw0Q4Muexq9bi0DJwx_mJ-' \
--data-urlencode 'pageurl=https://www.google.com/recaptcha/api2/demo' \
--data-urlencode 'proxy=testuser1:testpassword@154.21.34.42:21298' \
--data-urlencode 'proxytype=HTTP' \
--data-urlencode 'json=1'
SOCKS5 proxy request
curl --request POST 'https://ocr.captchaai.com/in.php' \
--data-urlencode 'key=YOUR_CAPTCHAAI_API_KEY' \
--data-urlencode 'method=userrecaptcha' \
--data-urlencode 'googlekey=6Le-wvkSAAAAAPBMRTvw0Q4Muexq9bi0DJwx_mJ-' \
--data-urlencode 'pageurl=https://www.google.com/recaptcha/api2/demo' \
--data-urlencode 'proxy=testuser1:testpassword@213.139.196.104:31290' \
--data-urlencode 'proxytype=SOCKS5' \
--data-urlencode 'json=1'
A successful submission returns a task identifier:
{"status":1,"request":"CAPTCHA_TASK_ID"}
Retrieve the result
Wait approximately 15 seconds, then replace CAPTCHA_TASK_ID with the value returned by in.php.
curl --get 'https://ocr.captchaai.com/res.php' \
--data-urlencode 'key=YOUR_CAPTCHAAI_API_KEY' \
--data-urlencode 'action=get' \
--data-urlencode 'id=CAPTCHA_TASK_ID' \
--data-urlencode 'json=1'
If CaptchaAI returns CAPCHA_NOT_READY, wait approximately 5 seconds and poll the existing task again. A successful result contains the solution token:
{"status":1,"request":"CAPTCHA_SOLUTION_TOKEN"}
Keep the session consistent
- Configure the browser or client with one HighProxies proxy.
- Load the authorized target page through that proxy.
- Extract the current page URL and CAPTCHA site key.
- Submit the CaptchaAI task with the same proxy.
- Poll CaptchaAI for the solution.
- Submit the token through the original session and proxy.
- Change the proxy only after the transaction finishes.
Python Example for HTTP and SOCKS5
Change PROXY_MODE to HTTP or SOCKS5. In production, load the API key and proxy credentials from server-side environment variables or a secrets manager.
import time
import requests
API_KEY = "YOUR_CAPTCHAAI_API_KEY"
SITE_KEY = "6Le-wvkSAAAAAPBMRTvw0Q4Muexq9bi0DJwx_mJ-"
PAGE_URL = "https://www.google.com/recaptcha/api2/demo"
PROXY_MODE = "HTTP"
PROXIES = {
"HTTP": "testuser1:testpassword@154.21.34.42:21298",
"SOCKS5": "testuser1:testpassword@213.139.196.104:31290",
}
submit_response = requests.post(
"https://ocr.captchaai.com/in.php",
data={
"key": API_KEY,
"method": "userrecaptcha",
"googlekey": SITE_KEY,
"pageurl": PAGE_URL,
"proxy": PROXIES[PROXY_MODE],
"proxytype": PROXY_MODE,
"json": 1,
},
timeout=30,
)
submit_response.raise_for_status()
submit_result = submit_response.json()
if submit_result.get("status") != 1:
raise RuntimeError(f"CaptchaAI rejected the task: {submit_result}")
task_id = submit_result["request"]
time.sleep(15)
while True:
result_response = requests.get(
"https://ocr.captchaai.com/res.php",
params={
"key": API_KEY,
"action": "get",
"id": task_id,
"json": 1,
},
timeout=30,
)
result_response.raise_for_status()
result = result_response.json()
if result.get("status") == 1:
print(result["request"])
break
if result.get("request") != "CAPCHA_NOT_READY":
raise RuntimeError(f"CaptchaAI task failed: {result}")
time.sleep(5)
Troubleshooting CaptchaAI Proxy Connections
Proxy parameters are rejected
Confirm that CaptchaAI support enabled proxy usage for your account. It is disabled by default.
Authentication fails
Verify the username, password and port. Remove copied spaces and use USERNAME:PASSWORD@IP:PORT.
Wrong proxy type
Use HTTP for the HTTP/HTTPS private proxy and SOCKS5 for the SOCKS5 service.
Works locally but not in CaptchaAI
Use username/password authentication. A proxy authorized only for your local public IP will reject CaptchaAI's connection.
ERROR_ZERO_BALANCE
Add funds, buy threads or reduce concurrency. CaptchaAI cannot accept the task without available capacity.
CAPCHA_NOT_READY
The task is still processing. Wait approximately 5 seconds and poll the existing task again.
Cloudflare Challenge
For CaptchaAI's full-page Cloudflare Challenge method, reuse the exact proxy and returned User-Agent with the cf_clearance cookie. The cookie is bound to both the solver IP and User-Agent.
Account security
- Use the API key supplied by your own CaptchaAI account.
- Use the proxy details assigned to your own HighProxies service.
- Keep API keys and proxy credentials in server-side environment variables or a secrets manager.
- Do not expose credentials in public source code, browser-side JavaScript or screenshots.
- Use the integration only for lawful, authorized workflows.
Dedicated static datacenter proxies
Choose the Protocol Your Application Supports
Use a dedicated HTTP/HTTPS proxy for conventional web traffic or a dedicated SOCKS5 service for compatible TCP applications. Keep the same proxy identity until the CAPTCHA transaction is complete.