CAPSOLVER
Blog
How to Solve CAPTCHA in RoxyBrowser with CapSolver Integration

How to Solve Captcha in RoxyBrowser with CapSolver Integration

Logo of CapSolver

Lucas Mitchell

Automation Engineer

04-Feb-2026

RoxyBrowser provides browser functionality through API calls and can be integrated with automation frameworks like Selenium, Puppeteer, and Playwright. Its API is designed to let you open real browser profiles programmatically and attach your automation tooling. The API has a documented rate limit of 100 calls per minute per endpoint.
Source: https://faq.roxybrowser.org/en/guide/10-API

CapSolver provides a create-and-poll API flow that returns a CAPTCHA token you can inject into the page. CapSolver supports multiple CAPTCHA types:

  • reCAPTCHA v2: Task type ReCaptchaV2TaskProxyLess, returns gRecaptchaResponse
  • reCAPTCHA v3: Task type ReCaptchaV3TaskProxyLess, returns gRecaptchaResponse with score
  • Cloudflare Turnstile: Task type AntiTurnstileTaskProxyLess, returns token Check the docs

This guide shows a practical, framework-agnostic flow: open a Roxy profile via API, attach your automation framework, solve the CAPTCHA with CapSolver, and inject the token to continue.


What is RoxyBrowser?

RoxyBrowser is an antidetect browser for multi-accounting with features like API automation and multi-window synchronizer.

For automation, the API is the most relevant piece:

  • It supports Selenium, Puppeteer, and Playwright integration.

  • Requests must include a token header.

  • Default API host is http://127.0.0.1:50000 (port change requires restart).


What is CapSolver?

CapSolver solves CAPTCHAs through two API calls:

  1. createTask to submit the CAPTCHA parameters
  2. getTaskResult to poll until the token is ready

For reCAPTCHA v2, CapSolver returns gRecaptchaResponse.

getTaskResult is limited to 120 queries per task and must be called within 5 minutes of task creation.

RoxyBrowser API Setup

1) Enable the API and get your token

  1. Open RoxyBrowser and go to API.
  2. Set the API switch to Enabled.
  3. Copy the API key (token) and confirm the host/port.

By default, the host is http://127.0.0.1:50000. If you change the port, you must restart RoxyBrowser.

2) Get workspace and profile IDs

Use /browser/workspace to fetch workspaces, then /browser/list_v3 to list profiles.

python Copy
import requests

BASE = "http://127.0.0.1:50000"
HEADERS = {"token": "YOUR_ROXY_API_KEY"}

workspaces = requests.get(f"{BASE}/browser/workspace", headers=HEADERS).json()
workspace_id = workspaces["data"]["rows"][0]["id"]

profiles = requests.get(
    f"{BASE}/browser/list_v3",
    params={"workspaceId": workspace_id},
    headers=HEADERS
).json()
dir_id = profiles["data"]["rows"][0]["dirId"]

3) Open a profile and capture automation endpoints

Call /browser/open. The response includes:

  • ws: WebSocket interface for automation tools
  • http: HTTP interface for automation tools
  • driver: WebDriver path for Selenium integration

Headless mode is not supported.

python Copy
open_resp = requests.post(
    f"{BASE}/browser/open",
    json={"workspaceId": workspace_id, "dirId": dir_id, "args": []},
    headers=HEADERS
).json()

ws_endpoint = open_resp["data"]["ws"]
http_endpoint = open_resp["data"]["http"]
driver_path = open_resp["data"]["driver"]

4) Attach your automation framework

Use the returned endpoints to attach your framework:

  • Puppeteer/Playwright can connect via the DevTools WebSocket or HTTP endpoint.
  • Selenium can use the driver path with a debugger connection.

The exact attach steps depend on your framework, but the ws, http, and driver values are explicitly provided for automation tools.


CapSolver Helper (Python)

python Copy
import time
import requests

CAPSOLVER_API_KEY = "YOUR_CAPSOLVER_API_KEY"
CAPSOLVER_BASE = "https://api.capsolver.com"

def create_task(task):
    payload = {"clientKey": CAPSOLVER_API_KEY, "task": task}
    r = requests.post(f"{CAPSOLVER_BASE}/createTask", json=payload)
    data = r.json()
    if data.get("errorId", 0) != 0:
        raise RuntimeError(data.get("errorDescription", "CapSolver error"))
    return data["taskId"]

def get_task_result(task_id, delay=2):
    while True:
        time.sleep(delay)
        r = requests.post(
            f"{CAPSOLVER_BASE}/getTaskResult",
            json={"clientKey": CAPSOLVER_API_KEY, "taskId": task_id}
        )
        data = r.json()
        if data.get("status") == "ready":
            return data["solution"]
        if data.get("status") == "failed":
            raise RuntimeError(data.get("errorDescription", "Task failed"))

def solve_recaptcha_v2(website_url, website_key):
    task = {
        "type": "ReCaptchaV2TaskProxyLess",
        "websiteURL": website_url,
        "websiteKey": website_key
    }
    task_id = create_task(task)
    solution = get_task_result(task_id)
    return solution.get("gRecaptchaResponse", "")

def solve_recaptcha_v3(website_url, website_key, page_action="verify"):
    task = {
        "type": "ReCaptchaV3TaskProxyLess",
        "websiteURL": website_url,
        "websiteKey": website_key,
        "pageAction": page_action
    }
    task_id = create_task(task)
    solution = get_task_result(task_id)
    return solution.get("gRecaptchaResponse", "")

def solve_turnstile(website_url, website_key, action=None, cdata=None):
    task = {
        "type": "AntiTurnstileTaskProxyLess",
        "websiteURL": website_url,
        "websiteKey": website_key
    }
    # Add optional metadata if provided
    if action or cdata:
        task["metadata"] = {}
        if action:
            task["metadata"]["action"] = action
        if cdata:
            task["metadata"]["cdata"] = cdata

    task_id = create_task(task)
    solution = get_task_result(task_id)
    return solution.get("token", "")

For Reference:

End-to-End Flow: reCAPTCHA v2

  1. Open a Roxy profile via /browser/open and attach your automation framework.

  2. Navigate to the target page and extract the site key.
    Example:

    javascript Copy
    const siteKey = document.querySelector(".g-recaptcha")?.getAttribute("data-sitekey");
  3. Solve with CapSolver using the helper above.

  4. Inject the token and submit the form:

    javascript Copy
    const token = "CAPSOLVER_TOKEN";
    const el = document.getElementById("g-recaptcha-response");
    el.style.display = "block";
    el.value = token;
    el.dispatchEvent(new Event("input", { bubbles: true }));
    el.dispatchEvent(new Event("change", { bubbles: true }));

End-to-End Flow: reCAPTCHA v3

reCAPTCHA v3 works differently - it runs in the background and returns a score (0.0 to 1.0) instead of requiring user interaction.

  1. Extract the site key and action from the page:

    javascript Copy
    // Site key is usually in a script or meta tag
    const siteKey = document.querySelector('[data-sitekey]')?.getAttribute('data-sitekey');
    
    // Action is found in grecaptcha.execute calls
    // Search page source for: grecaptcha.execute('KEY', {action: 'ACTION'})
    const pageAction = "submit"; // or "login", "register", etc.
  2. Solve with CapSolver:

    python Copy
    token = solve_recaptcha_v3(
        website_url="https://example.com/login",
        website_key="6LcxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxAA",
        page_action="login"
    )
  3. Inject the token (same as v2):

    javascript Copy
    const token = "CAPSOLVER_TOKEN";
    document.getElementById("g-recaptcha-response").value = token;
    
    // If there's a callback, trigger it
    if (typeof ___grecaptcha_cfg !== 'undefined') {
        const clients = ___grecaptcha_cfg.clients;
        Object.keys(clients).forEach(key => {
            if (clients[key].callback) {
                clients[key].callback(token);
            }
        });
    }

End-to-End Flow: Cloudflare Turnstile

Cloudflare Turnstile is a modern CAPTCHA alternative that's faster to solve (1-20 seconds).

  1. Extract the Turnstile site key:

    javascript Copy
    const siteKey = document.querySelector('.cf-turnstile')?.getAttribute('data-sitekey');
    // Optional: extract action and cdata if present
    const action = document.querySelector('.cf-turnstile')?.getAttribute('data-action');
    const cdata = document.querySelector('.cf-turnstile')?.getAttribute('data-cdata');
  2. Solve with CapSolver:

    python Copy
    token = solve_turnstile(
        website_url="https://example.com",
        website_key="0x4AAAAAAAxxxxxxxxxxxxxxx",
        action=action,  # optional
        cdata=cdata     # optional
    )
  3. Inject the Turnstile token:

    javascript Copy
    const token = "CAPSOLVER_TURNSTILE_TOKEN";
    
    // Find the Turnstile response input
    const input = document.querySelector('input[name="cf-turnstile-response"]');
    if (input) {
        input.value = token;
        input.dispatchEvent(new Event('input', { bubbles: true }));
        input.dispatchEvent(new Event('change', { bubbles: true }));
    }
    
    // Alternative: some sites use a different input name
    const altInput = document.querySelector('input[name="turnstile-response"]');
    if (altInput) {
        altInput.value = token;
    }

Best Practices

  • Respect RoxyBrowser's API rate limit: 100 calls per minute per endpoint.
  • CapSolver getTaskResult is limited to 120 polls within 5 minutes.
  • Use retry logic and backoff if tokens are rejected.
  • Keep the solver IP and browsing IP consistent when the target site validates token origin.

Ready to get started? Sign up for CapSolver and use bonus code ROXYBROWSER for an extra 6% bonus on your first recharge!

FAQ

  • Does RoxyBrowser support Selenium, Puppeteer, and Playwright?
    Yes. The API is designed for integration with these frameworks.

  • Where do I get the API token and host?
    From API -> API Configuration in RoxyBrowser. The default host is http://127.0.0.1:50000.

  • What does /browser/open return?
    It returns ws, http, and driver fields used by automation tools.

  • Is headless supported?
    No, headless mode is not supported.

  • What CAPTCHA types does CapSolver support?

  • How does CapSolver return reCAPTCHA v2 tokens?
    Create a task with ReCaptchaV2TaskProxyLess and poll getTaskResult for gRecaptchaResponse.

  • How does reCAPTCHA v3 differ from v2?
    reCAPTCHA v3 runs in the background without user interaction and returns a score (0.0-1.0). It requires the pageAction parameter, which can be found by searching for grecaptcha.execute in the page source.

  • How do I solve Cloudflare Turnstile?
    Use task type AntiTurnstileTaskProxyLess with websiteURL and websiteKey. Optionally include metadata.action and metadata.cdata if present on the widget. Turnstile solves in 1-20 seconds.
    Further Reading:

  • How do I find the Turnstile site key?
    Look for the data-sitekey attribute on the .cf-turnstile element. Turnstile site keys start with 0x4.

  • Do I need a proxy for CapSolver?
    No, the *ProxyLess task types use CapSolver's built-in proxy infrastructure. Use the non-ProxyLess variants if you need to use your own proxies.

Conclusion

RoxyBrowser gives you a profile-based browser environment with automation endpoints, and CapSolver provides programmatic CAPTCHA tokens. By opening a Roxy profile, attaching your framework, and injecting CapSolver tokens, you can build reliable CAPTCHA-aware automation flows.

Compliance Disclaimer: The information provided on this blog is for informational purposes only. CapSolver is committed to compliance with all applicable laws and regulations. The use of the CapSolver network for illegal, fraudulent, or abusive activities is strictly prohibited and will be investigated. Our captcha-solving solutions enhance user experience while ensuring 100% compliance in helping solve captcha difficulties during public data crawling. We encourage responsible use of our services. For more information, please visit our Terms of Service and Privacy Policy.

More

Solve Captcha with Nanobrowser and CapSolver
How to Solve Captcha with Nanobrowser and CapSolver Integration

Solve reCAPTCHA and Cloudflare Turnstile automatically by integrating Nanobrowser with CapSolver for seamless AI automation.

web scraping
Logo of CapSolver

Ethan Collins

04-Feb-2026

RoxyBrowser with CapSolver Integration
How to Solve Captcha in RoxyBrowser with CapSolver Integration

Integrate CapSolver with RoxyBrowser to automate browser tasks and bypass reCAPTCHA, Turnstile, and other CAPTCHAs.

web scraping
Logo of CapSolver

Lucas Mitchell

04-Feb-2026

Easyspider CapSolver Captcha Integration
How to Solve Captcha in EasySpider with CapSolver Integration

EasySpider is a visual, no-code web scraping and browser automation tool, and when combined with CapSolver, it can reliably solve CAPTCHAs like reCAPTCHA v2 and Cloudflare Turnstile, enabling seamless automated data extraction across websites.

web scraping
Logo of CapSolver

Lucas Mitchell

04-Feb-2026

Relevance AI with CapSolver
How to Solve reCAPTCHA v2 in Relevance AI with CapSolver Integration

Build a Relevance AI tool to solve reCAPTCHA v2 using CapSolver. Automate form submissions via API without browser automation.

web scraping
Logo of CapSolver

Lucas Mitchell

03-Feb-2026

Web Scraping in Node.js: Using Node Unblocker and CapSolver
Web Scraping in Node.js: Using Node Unblocker and CapSolver

Master web scraping in Node.js using Node Unblocker to bypass restrictions and CapSolver to solve CAPTCHAs. This guide provides advanced strategies for efficient and reliable data extraction.

web scraping
Logo of CapSolver

Nikolai Smirnov

03-Feb-2026

Instant Data Scraper Tools: Fast Ways to Extract Web Data Without Code
Instant Data Scraper Tools: Fast Ways to Extract Web Data Without Code

Discover the best instant data scraper tools for 2026. Learn fast ways to extract web data without code using top extensions and APIs for automated extraction.

web scraping
Logo of CapSolver

Emma Foster

27-Jan-2026