Troubleshooting

Fix ERROR_CAPTCHA_UNSOLVABLE

ERROR_CAPTCHA_UNSOLVABLE means CaptchaAI's workers couldn't solve the CAPTCHA challenge. This guide covers why it happens and how to fix it.

Common Causes

Cause Likelihood Fix
Expired or stale challenge High Request a fresh CAPTCHA and retry
Invalid sitekey Medium Verify the sitekey from page source
Wrong method parameter Medium Match method to CAPTCHA type
Corrupted or unreadable image Medium Check image encoding
Honeypot CAPTCHA Low Skip — it's designed to be unsolvable
Site-specific anti-bot Low Add cookies, user-agent, or proxy

Diagnosis Steps

Step 1: Check Your Parameters

Verify you're using the correct method and parameters:

# ✅ Correct reCAPTCHA v2
params = {
    "method": "userrecaptcha",
    "googlekey": "6Le-wvkS...",       # Must match site
    "pageurl": "https://example.com",  # Must be exact page URL
}

# ❌ Common mistakes
params = {
    "method": "recaptcha",        # Wrong method name
    "googlekey": "wrong_key",     # Stale or wrong sitekey
    "pageurl": "example.com",     # Missing protocol
}

Step 2: Verify the Sitekey

Extract the sitekey from the live page:

import requests
import re

resp = requests.get("https://example.com")
match = re.search(r'data-sitekey=["\']([A-Za-z0-9_-]+)["\']', resp.text)
if match:
    print(f"Sitekey: {match.group(1)}")
else:
    print("No reCAPTCHA found on page")

Sites can change sitekeys. Always extract dynamically rather than hardcoding.

Step 3: Check for Fresh Challenge

For reCAPTCHA, the challenge must be current. Submit immediately after loading the page:

# ✅ Good: fetch page, extract key, solve immediately
resp = requests.get("https://example.com/form")
site_key = extract_sitekey(resp.text)
token = solve_captcha(site_key, "https://example.com/form")

# ❌ Bad: using a sitekey from hours ago
old_site_key = "saved_from_yesterday"
token = solve_captcha(old_site_key, url)  # May be unsolvable

Step 4: Check Image Quality (for Image CAPTCHAs)

import base64

with open("captcha.png", "rb") as f:
    data = f.read()

# Verify it's a valid image
if len(data) < 100:
    print("Image too small — likely corrupted")
elif len(data) > 100000:
    print("Image too large — compress before sending")
else:
    print(f"Image OK: {len(data)} bytes")

# Verify base64 encoding
b64 = base64.b64encode(data).decode()
decoded = base64.b64decode(b64)
assert decoded == data, "Base64 encoding mismatch"

Retry Strategy

Implement automatic retry with a fresh challenge:

import requests
import time

API_KEY = "YOUR_API_KEY"


def solve_with_retry(params, max_retries=3):
    for attempt in range(max_retries):
        # Submit
        resp = requests.get("https://ocr.captchaai.com/in.php", params={
            **params, "key": API_KEY,
        })

        if not resp.text.startswith("OK|"):
            if resp.text == "ERROR_CAPTCHA_UNSOLVABLE":
                print(f"Unsolvable (attempt {attempt + 1}), retrying...")
                time.sleep(2)
                continue
            raise Exception(f"Submit error: {resp.text}")

        task_id = resp.text.split("|")[1]

        # Poll
        for _ in range(60):
            time.sleep(5)
            result = requests.get("https://ocr.captchaai.com/res.php", params={
                "key": API_KEY, "action": "get", "id": task_id,
            })

            if result.text == "CAPCHA_NOT_READY":
                continue
            if result.text.startswith("OK|"):
                return result.text.split("|", 1)[1]
            if result.text == "ERROR_CAPTCHA_UNSOLVABLE":
                print(f"Unsolvable during solve (attempt {attempt + 1})")
                break
            raise Exception(f"Poll error: {result.text}")

    raise Exception(f"Unsolvable after {max_retries} attempts")

When to Stop Retrying

  • After 3 retries: The CAPTCHA may be a honeypot or deliberately unsolvable
  • If sitekey doesn't match: Fix the sitekey instead of retrying
  • If the site has changed: Update your scraper to handle new page structure

Report Unsolvable CAPTCHAs

Help improve CaptchaAI's accuracy by reporting problematic CAPTCHAs:

def report_bad(task_id):
    requests.get("https://ocr.captchaai.com/res.php", params={
        "key": API_KEY,
        "action": "reportbad",
        "id": task_id,
    })

FAQ

Does ERROR_CAPTCHA_UNSOLVABLE cost me?

No. You are not charged for unsolvable CAPTCHAs. Only successful solves are billed.

Why does the same CAPTCHA type work sometimes and fail other times?

CAPTCHAs have varying difficulty. Some challenges are harder for workers. Retrying with a fresh challenge usually succeeds.

Is there a way to prevent this error?

Use correct parameters, fresh sitekeys, and include cookies/user-agent for context. This reduces unsolvable rates to <2%.

Discussions (0)

No comments yet.

Related Posts

Reference CAPTCHA Token Injection Methods Reference
Complete reference for injecting solved CAPTCHA tokens into web pages.

Complete reference for injecting solved CAPTCHA tokens into web pages. Covers re CAPTCHA, Turnstile, and Cloud...

Automation Python reCAPTCHA v2
Apr 08, 2026
Tutorials Pytest Fixtures for CaptchaAI API Testing
Build reusable pytest fixtures to test CAPTCHA-solving workflows with Captcha AI.

Build reusable pytest fixtures to test CAPTCHA-solving workflows with Captcha AI. Covers mocking, live integra...

Automation Python reCAPTCHA v2
Apr 08, 2026
API Tutorials How to Solve reCAPTCHA v2 Callback Using API
how to solve re CAPTCHA v 2 callback implementations using Captcha AI API.

Learn how to solve re CAPTCHA v 2 callback implementations using Captcha AI API. Detect the callback function,...

Automation reCAPTCHA v2 Webhooks
Mar 01, 2026
Reference Browser Session Persistence for CAPTCHA Workflows
Manage browser sessions, cookies, and storage across CAPTCHA-solving runs to reduce repeat challenges and maintain authenticated state.

Manage browser sessions, cookies, and storage across CAPTCHA-solving runs to reduce repeat challenges and main...

Automation Python reCAPTCHA v2
Feb 24, 2026
Integrations Browser Profile Isolation + CaptchaAI Integration
Browser profile isolation tools create distinct browser environments with unique fingerprints per session.

Browser profile isolation tools create distinct browser environments with unique fingerprints per session. Com...

Automation Python reCAPTCHA v2
Feb 21, 2026
Tutorials Securing CaptchaAI Credentials in Environment Variables
Store Captcha AI API keys securely using environment variables, .env files, Docker secrets, and cloud secret managers instead of hardcoding.

Store Captcha AI API keys securely using environment variables, .env files, Docker secrets, and cloud secret m...

Automation Python reCAPTCHA v2
Feb 12, 2026
Comparisons WebDriver vs Chrome DevTools Protocol for CAPTCHA Automation
Compare Web Driver and Chrome Dev Tools Protocol (CDP) for CAPTCHA automation — detection, performance, capabilities, and when to use each with Captcha AI.

Compare Web Driver and Chrome Dev Tools Protocol (CDP) for CAPTCHA automation — detection, performance, capabi...

Automation Python reCAPTCHA v2
Mar 27, 2026
Use Cases Event Ticket Monitoring with CAPTCHA Handling
Build an event ticket availability monitor that handles CAPTCHAs using Captcha AI.

Build an event ticket availability monitor that handles CAPTCHAs using Captcha AI. Python workflow for checkin...

Automation Python reCAPTCHA v2
Jan 17, 2026
Use Cases CAPTCHA Solving in Ticket Purchase Automation
How to handle CAPTCHAs on ticketing platforms Ticketmaster, AXS, and event sites using Captcha AI for automated purchasing workflows.

How to handle CAPTCHAs on ticketing platforms Ticketmaster, AXS, and event sites using Captcha AI for automate...

Automation Python reCAPTCHA v2
Feb 25, 2026
Tutorials Caching CAPTCHA Tokens for Reuse
Cache and reuse CAPTCHA tokens with Captcha AI to reduce API calls and costs.

Cache and reuse CAPTCHA tokens with Captcha AI to reduce API calls and costs. Covers token lifetimes, cache st...

Automation Python reCAPTCHA v2
Feb 15, 2026
Troubleshooting GeeTest v3 Error Codes: Complete Troubleshooting Reference
Complete reference for Gee Test v 3 error codes — from registration failures to validation errors — with causes, fixes, and Captcha AI-specific troubleshooting.

Complete reference for Gee Test v 3 error codes — from registration failures to validation errors — with cause...

Automation Testing GeeTest v3
Apr 08, 2026
Troubleshooting Turnstile Token Invalid After Solving: Diagnosis and Fixes
Fix Cloudflare Turnstile tokens that come back invalid after solving with Captcha AI.

Fix Cloudflare Turnstile tokens that come back invalid after solving with Captcha AI. Covers token expiry, sit...

Python Cloudflare Turnstile Web Scraping
Apr 08, 2026
Troubleshooting Common GeeTest v3 Errors and Fixes
Diagnose the most common Gee Test v 3 errors — stale challenge, bad parameters, validation failures — and fix them with practical troubleshooting steps.

Diagnose the most common Gee Test v 3 errors — stale challenge, bad parameters, validation failures — and fix...

Automation Testing GeeTest v3
Jan 24, 2026