Google reCAPTCHA v2, v3, & Enterprise Solving Guide
Google reCAPTCHA is deployed across over 10 million websites. Understanding the mechanical differences between v2 Checkbox, v3 Score-Based, and Google Cloud Enterprise is essential for building reliable scraping pipelines.
Why 2Captcha Leads in reCAPTCHA Solving
In our benchmark evaluation across 24 platforms, 2Captcha maintained the highest accuracy and completion metrics on reCAPTCHA challenges: 99.4% resolution success rate, dedicated support for v3 0.9 score thresholds, and native reCAPTCHA Enterprise parameter handling.
Comparing Google reCAPTCHA Implementations
Automated scrapers frequently encounter three distinct variants of Google reCAPTCHA. Treating them identically leads to authentication failures, rejected form submissions, and wasted solving credits.
| Feature | reCAPTCHA v2 | reCAPTCHA v3 | reCAPTCHA Enterprise |
|---|---|---|---|
| User Interaction | Checkbox ("I'm not a robot") + image tiles | Completely invisible | Invisible or risk-adaptive challenge |
| Evaluation Mode | Binary (pass / fail) | Score (0.0 bot to 1.0 human) | Risk score + granular threat reasons |
| Critical Parameters | sitekey, url | sitekey, url, action, minScore | sitekey, url, action, enterprise=1 |
| 2Captcha Rate | $1.00 / 1,000 | $1.00 / 1,000 | $1.50 / 1,000 |
1. Solving reCAPTCHA v2 (Checkbox & Invisible)
In reCAPTCHA v2, the target page embeds an element with class="g-recaptcha" and a data-sitekey attribute. When passed to 2Captcha, human workers or emulated AI browsers solve the interactive challenge and return the g-recaptcha token:
from twocaptcha import TwoCaptcha
solver = TwoCaptcha("YOUR_2CAPTCHA_API_KEY")
# Solve standard reCAPTCHA v2 Checkbox or Invisible
result = solver.recaptcha(
sitekey="6Le-wvkSAAAAAPBMRTvw0Q4Muexq9bi0DJwx_mJ-",
url="https://example.com/login"
)
token = result["code"]
print(f"Solved v2 in {result.get('solve_time', 'N/A')}s: {token[:40]}...")2. Solving reCAPTCHA v3 with Target Scores (0.9)
reCAPTCHA v3 returns a score between 0.0 (likely bot) and 1.0 (likely human). High-security endpoints (like financial portals, login gateways, or sneaker drops) configure their backend verification to reject any request with a score under 0.7 or 0.9.
To succeed on v3, you must pass the exact action defined in the target site's JavaScript call (e.g., grecaptcha.execute('SITEKEY', {action: 'homepage'})) and request a high score threshold from 2Captcha:
from twocaptcha import TwoCaptcha
solver = TwoCaptcha("YOUR_2CAPTCHA_API_KEY")
# Solve reCAPTCHA v3 with target score (0.9 high reputation)
result = solver.recaptcha(
sitekey="6LdyC2cUAAAAABpQI5b839um9T4vj_xM8-oXkZpG",
url="https://example.com/checkout",
version="v3",
action="checkout", # Must match the action parameter in grecaptcha.execute
score=0.9 # Target human score threshold (0.1 to 0.9)
)
token = result["code"]
print(f"Solved v3 with score 0.9 in {result.get('solve_time', 'N/A')}s: {token[:40]}...")3. Solving Google reCAPTCHA Enterprise
reCAPTCHA Enterprise runs on Google Cloud Platform and uses advanced telemetry, cryptographic payload watermarking, and assessment tokens. In HTML source code, Enterprise scripts load from www.google.com/recaptcha/enterprise.js rather than the standard api.js.
Solving Enterprise challenges requires passing enterprise=1 to 2Captcha so the task is routed through specialized Enterprise worker nodes:
from twocaptcha import TwoCaptcha
solver = TwoCaptcha("YOUR_2CAPTCHA_API_KEY")
# Solve Google reCAPTCHA Enterprise
result = solver.recaptcha(
sitekey="6LfW6wATAAAAAHLqO2yKSmYhD8uM2b4lQ-zNfF8-",
url="https://target-portal.com/enterprise-login",
enterprise=1, # Flag to route task to 2Captcha Enterprise engine
action="login" # Enterprise action token context
)
token = result["code"]
print(f"Enterprise token received: {token[:40]}...")4. Injecting Tokens & Firing Callbacks
In automated browser frameworks (Playwright, Puppeteer, Selenium), receiving the token from 2Captcha is only half the battle. You must inject the token into #g-recaptcha-response and invoke the client-side JavaScript callback registered by Google's client library:
// Client-side JavaScript evaluation to insert token and fire callback
function injectRecaptchaToken(token) {
// 1. Write token into the hidden response textarea
const textarea = document.getElementById("g-recaptcha-response") ||
document.querySelector('textarea[name="g-recaptcha-response"]');
if (textarea) {
textarea.value = token;
textarea.style.display = "block"; // Required on some strict forms
}
// 2. Locate and invoke any registered reCAPTCHA callback
if (typeof ___grecaptcha_cfg !== "undefined" && ___grecaptcha_cfg.clients) {
Object.values(___grecaptcha_cfg.clients).forEach(client => {
Object.values(client).forEach(item => {
if (item && typeof item.callback === "function") {
item.callback(token);
}
});
});
}
}