For AI agents: a documentation index is available at /llms.txt
Skip to main content

Solving reCAPTCHAs

Automatically detect and solve reCAPTCHA v2, v3, invisible, and other CAPTCHA challenges during browser automation.

Prerequisites

Steps

Use BrowserQL over HTTP to navigate a CAPTCHA page and solve it in a single mutation.

View Full Code on GitHub

1. Build the BrowserQL mutation

Use the BQL solve mutation, which auto-detects and solves any CAPTCHA on the current page:

https://production-sfo.browserless.io/chromium/bql?token=YOUR_API_TOKEN_HERE

2. Send the request

curl -X POST \
"https://production-sfo.browserless.io/chromium/bql?token=YOUR_API_TOKEN_HERE" \
-H "Content-Type: application/json" \
-d '{
"query": "mutation SolveCaptcha { goto(url: \"https://www.google.com/recaptcha/api2/demo\") { status } solve { found solved time token } submit: click(selector: \"#recaptcha-demo-submit\") { time } }"
}'

3. Check the output

{
"data": {
"goto": { "status": 200 },
"solve": { "found": true, "solved": true, "time": 4800, "token": "03AGdBq..." },
"submit": { "time": 95 }
}
}

Next steps