reCAPTCHA v3 returns a score (0.0 to 1.0) instead of a challenge. It tracks user behavior across the session. For automation, you need to solve v3 by generating tokens with appropriate scores. DeathByCaptcha handles v3 token generation.
How reCAPTCHA v3 Works
- The page loads reCAPTCHA v3 with a sitekey and action (e.g., "login").
- reCAPTCHA runs silently in the background.
- It returns a token with a score (0.0 = bot, 1.0 = human).
- The server validates the token against the score threshold.
Detecting reCAPTCHA v3
# Check for reCAPTCHA v3
v3_script = page.query_selector("script[src*=recaptcha/enterprise?render=]")
if v3_script:
src = v3_script.get_attribute("src")
sitekey = src.split("render=")[1].split("&")[0]
print(f"reCAPTCHA v3 sitekey: {sitekey}")
Solving with DeathByCaptcha
reCAPTCHA v3 uses type=5:
import json
from playwright.sync_api import sync_playwright
import deathbycaptcha
client = deathbycaptcha.SocketClient(username, password)
with sync_playwright() as p:
browser = p.chromium.launch(headless=True)
page = browser.new_page()
page.goto("https://example.com/login")
v3_script = page.query_selector("script[src*=recaptcha/enterprise?render=]")
sitekey = v3_script.get_attribute("src").split("render=")[1].split("&")[0]
result = client.decode(type=5, token_params=json.dumps({
"googlekey": sitekey,
"pageurl": "https://example.com/login",
"action": "login"
}))
print("Solution:", result["text"])
page.evaluate("document.querySelector(\"[name=g-recaptcha-response]\").value=\"%s\"" % result["text"])
page.click("button[type=submit]")
browser.close()
Key Differences from v2
- Type parameter: Use type=5 for v3, type=4 for visible v2, type=2 for invisible v2.
- No challenge: v3 never shows a visual challenge. It returns a score.
- Action parameter: Pass the action string (e.g., "login", "checkout") used in the page.
- Score handling: The API returns tokens with scores. Higher scores pass more validation.
Enterprise vs Standard
Enterprise reCAPTCHA v3 has additional features:
- Custom scoring rules per action.
- WAF integration for real-time blocking.
- Analytics dashboard for token usage.
Pass the enterprise flag for enterprise tokens:
result = client.decode(type=5, token_params=json.dumps({
"googlekey": sitekey,
"pageurl": page_url,
"action": "login",
"enterprise": True
}))
Troubleshooting
- Score too low: Increase the timeout parameter for better token quality.
- Action mismatch: Ensure the action parameter matches what the page expects.
- Domain mismatch: The pageurl must match the domain where reCAPTCHA is loaded.
For API documentation, see the API reference and client libraries.

English
Spanish
Russian
Chinese
French
Hindi
Arabic
Bengali
Indonesian
Portuguese
com, 