Skip to content
Guide

Camoufox Not Working in 2026: Fixing Cloudflare and Turnstile Failures

NSLSolver TeamPublished Updated 9 min read

When Camoufox fails Cloudflare or Turnstile, the browser fingerprint is rarely the cause. The project's own detection tracker points to proxy reputation, a mismatch between the proxy's location and the browser's timezone and locale, headless or Docker environments, and outdated builds. Fix those first: pass geoip=True with every proxy, use residential IPs, prefer headless="virtual" over plain headless on Linux, and upgrade both the package and the browser.

If a site still refuses to issue a Turnstile token after that, take Camoufox's own docs at their word: the browser makes automation hard to fingerprint, but it does not solve a captcha that is already on the screen. That last step needs a solver.

Quick answer: match your warning or symptom to the fix

Camoufox tells you a lot through its warnings and exceptions. These are the ones people search for, plus the symptoms behind most Cloudflare failures:

LeakWarning: When using a proxy, it is heavily recommended that you pass `geoip=True`.
Your timezone, locale, geolocation and WebRTC IP still describe your machine, not the proxy's exit IP. Add geoip=True (it needs the geoip extra).
NotInstalledGeoIPExtra
geoip was used without the optional GeoIP dependency. pip install -U "camoufox[geoip]", then run camoufox fetch.
Turnstile passes on my machine but fails in Docker
Long-running reports #311 and #574: datacenter IP, a 1x1 Xvfb screen and software rendering in the container. Use a residential IP, set CAMOUFOX_VIRTUAL_DISPLAY_SIZE, upgrade to the current build, or render on a GPU with headless="virtual-gpu".
CannotFindXvfb / VirtualDisplayNotSupported
headless="virtual" needs Linux and the Xvfb binary. sudo apt-get install xvfb on Debian or Ubuntu. On macOS or Windows, run headed.
Clicking the Turnstile checkbox does nothing
The checkbox sits in a cross-origin iframe, and a click bug at the content edge (#752) was fixed in September 2026. Run camoufox fetch for the current build, and try disable_coop=True (it warns).
A clean IP passes, every proxy fails
The maintainers' verdict on report #688: proxy reputation, not the browser fingerprint. Change proxy type or provider. Compare with stock Firefox on the same IP before blaming Camoufox.
ModuleNotFoundError: No module named 'browserforge'
Since 0.5.7 (October 2026) camoufox depends on fpgen instead of BrowserForge, so a fresh install no longer brings it in. Import Screen from camoufox.fingerprints and pass os and screen constraints.
Detected right after setting a custom user agent
A user agent that disagrees with the Firefox engine is a strong signal; the maintainers list it as a standing caveat. Let Camoufox generate the identity. Do not force a UA with i_know_what_im_doing.

Warning texts, options and versions checked against the Camoufox docs, GitHub and PyPI on 2026-12-01. Sources are listed at the end of the article.

Is Camoufox still maintained?

Yes, again, after a long gap. The browser releases on GitHub stop at v135.0.1-beta.24 on 15 March 2025. Nothing but a Firefox 146 prerelease (January 2026) followed until v150.0.2-beta.25 in May 2026. Since July 2026 builds have shipped every few weeks, and the latest is v159.0-beta.43 (22 November 2026). The Python package shows the same pattern: 0.4.11 in January 2025, then 0.5.3 in July 2026, and 0.5.9 on 1 November 2026. Every build is still labelled beta.

This matters for troubleshooting. The detection tracker (#686) notes that most open reports were filed against 135.0.1-beta.24 and calls a stale Firefox base "the single most common cause of detection reports". If you installed Camoufox in 2025 and never fetched a new browser, you are most likely still on Firefox 135.

The project has also been restructured: the Python and TypeScript launchers now live in CamouBrowser/camoucore, the camoufox package pins one camoucore release and one browser build, and the docs at camoufox.com also cover Camouwolf, a Chromium-based sibling in alpha.

upgrade.sh
pip install -U "camoufox[geoip]"
camoufox fetch     # installs the browser build this package release is paired with
camoufox version   # package, fpgen and Playwright versions, active build, GeoIP database

Why Camoufox fails Cloudflare and Turnstile

  • Proxy reputation. On report #688 the maintainers concluded "proxy reputation, not fingerprint": a clean IP passed, every proxy failed, and stock Firefox was detected too.
  • Location mismatch. Without geoip, a proxy in one country is paired with your own timezone, locale and WebRTC address. The launcher warns about exactly this.
  • HTTP proxies and UDP. An HTTP proxy carries no UDP, so WebRTC and HTTP/3 behave as on a machine whose firewall drops all UDP; the docs recommend a SOCKS5 proxy with UDP ASSOCIATE.
  • Headless and containers. Docs: headless mode "may still become detectable". In Docker, reports #311 and #574 describe Turnstile failing only inside the container; the maintainers point to the 1x1 Xvfb screen (#458) and software rendering, since Xvfb has no GPU.
  • Stale builds. See the section above.
  • Manual overrides. Setting navigator values, the user agent, ff_version or a custom fingerprint by hand triggers LeakWarnings for a reason: each creates a combination no real Firefox reports.
  • TLS. Camoufox is real Firefox, so its TLS handshake is Firefox's own; spoofing it is out of scope. A TLS-intercepting proxy such as mitmproxy replaces that fingerprint and gets you detected regardless of browser, as #686 notes.

Fix 1: proxy, geoip and the IP itself

geoip=True looks up the exit IP through the proxy and sets timezone, locale, geolocation and the WebRTC IP from it, and picks the language from the languages spoken in that region. The docs say residential proxies give the best results, and SOCKS5 proxies with a username and password are supported. Each NewContext() can have its own proxy and is placed at that proxy's exit.

Then test the IP on its own: if stock Firefox through the same proxy is also blocked, no browser setting will fix it.

proxy_geoip.py
from camoufox.sync_api import Camoufox

with Camoufox(
    # SOCKS5 carries UDP, so WebRTC and HTTP/3 leave from the proxy's exit too
    proxy={"server": "socks5://proxy.example.com:1080", "username": "user", "password": "pass"},
    geoip=True,           # timezone, locale, geolocation and WebRTC IP from the exit IP
    headless="virtual",   # Linux: headed browser on a private Xvfb display
) as browser:
    page = browser.new_page()
    page.goto("https://example.com")

Fix 2: headless, virtual display and Docker

  • Prefer headless="virtual" on Linux. It runs a headed browser on a private Xvfb display; the docs call it the safer choice than headless=True, which Camoufox patches but which "may still become detectable".
  • Give the display a real size. Camoufox's Xvfb screen is 1x1 unless CAMOUFOX_VIRTUAL_DISPLAY_SIZE says otherwise, for example 1920x1080x24.
  • Render on a GPU if you have one. headless="virtual-gpu" runs the browser on a private Xorg server bound to a card, so canvas and WebGL are not software-rendered. It fails with GpuSoftwareFallback if rendering never reaches the card.
  • In Docker, run camoufox fetch as the user that owns the Python environment, and install the Xvfb package in the image.
  • Claim the host's OS. An identity for another OS turns on canvas noise, and the browser then reads as a privacy-hardened Firefox rather than a stock one.

Fix 3: fingerprints, humanize and the Turnstile checkbox

Camoufox draws a complete device identity per launch from fpgen, a model of real-world traffic. It replaced BrowserForge, which earlier versions used: up to 0.5.6 the package depended on browserforge, from 0.5.7 on fpgen. Old snippets that import from browserforge or pass a BrowserForge fingerprint need updating; pass os and screen constraints instead and let the launcher generate the rest.

humanize is now driver-side: Playwright input calls are single events, and humanize=True replays recorded human mouse, typing and scrolling (older versions also accepted a float for the maximum cursor duration). For the Turnstile checkbox, the docs describe disable_coop as the option that lets you click elements in cross-origin iframes, such as that checkbox.

fingerprint.py
# Camoufox 0.5.7+ uses fpgen; BrowserForge is no longer installed
from camoufox.sync_api import Camoufox
from camoufox.fingerprints import Screen   # was: from browserforge.fingerprints import Screen

with Camoufox(
    screen=Screen(max_width=1920, max_height=1080),
    humanize=True,       # human-like mouse, typing and scrolling (myuri, in the driver)
    disable_coop=True,   # lets you click the Turnstile checkbox iframe (prints a warning)
) as browser:
    page = browser.new_page()
    page.goto("https://example.com")

When a solver is the right tool

Camoufox's documentation is direct about the boundary: the browsers make automation hard to fingerprint, but "they don't solve a captcha that is already on the screen". When a particular site keeps refusing to issue a Turnstile token from your best setup, solving the token outside the browser is the reliable step.

NSLSolver's turnstile type takes the widget's site_key and the page url and returns a token in about 250 ms on average, at $0.80 per 1,000 successful solves. For full-page Cloudflare challenges, the challenge type returns a cf_clearance cookie and its user_agent for $1.00 per 1,000. Only successful solves are billed, and sign-ups with Google, Gmail or Proton get free credit with no card. It does not solve reCAPTCHA v2, hCaptcha, image or text CAPTCHAs, FunCaptcha, GeeTest or DataDome. Only automate sites you own or are authorised to access.

Example: solve Turnstile and inject it into a Camoufox page

Camoufox runs page.evaluate in an isolated world that shares the DOM but not the page's JavaScript, so the hidden field can be set there. The widget's callback is a page function, so call it in the main world: launch with main_world_eval=True and prefix that one script with mw:. The docs warn that main-world code can be detected, so keep it to this single call at submit time.

camoufox_turnstile.py
import json
import requests
from camoufox.sync_api import Camoufox

def solve_turnstile(site_key: str, url: str) -> str:
    r = requests.post(
        "https://api.nslsolver.com/solve",
        headers={"X-API-Key": "nsl_YOUR_API_KEY"},
        json={"type": "turnstile", "site_key": site_key, "url": url},
        timeout=120,
    )
    data = r.json()
    if not data.get("success"):
        raise RuntimeError(data)
    return data["token"]

SET_FIELD = """(t) => {
  let input = document.querySelector('[name="cf-turnstile-response"]');
  if (!input) {
    input = Object.assign(document.createElement('input'),
      { type: 'hidden', name: 'cf-turnstile-response' });
    document.querySelector('form')?.appendChild(input);
  }
  input.value = t;
}"""

with Camoufox(main_world_eval=True, headless="virtual") as browser:
    page = browser.new_page()
    page.goto("https://example.com/login")

    site_key = page.get_attribute("[data-sitekey]", "data-sitekey")
    token = solve_turnstile(site_key, page.url)  # ~250 ms, valid 300 s, single use

    page.evaluate(SET_FIELD, token)  # isolated world: shares the DOM, invisible to the page
    cb = page.get_attribute("[data-callback]", "data-callback")
    if cb:  # the site's callback lives in the main world: use the mw: prefix
        page.evaluate(f"mw:window[{json.dumps(cb)}]({json.dumps(token)})")
    page.click("button[type=submit]")

Related guides

Frequently asked questions

Is Camoufox still maintained in 2026?

Yes. Browser releases paused after v135.0.1-beta.24 in March 2025 and resumed in 2026; since July 2026 builds ship every few weeks, the latest being v159.0-beta.43 on 22 November 2026. All builds are still labelled beta, and the launchers are now developed in CamouBrowser/camoucore.

Why does Camoufox get blocked by Cloudflare?

Most reports trace back to the IP or the environment rather than the fingerprint: proxy reputation, no geoip with a proxy, plain headless mode or a Docker container with a 1x1 virtual screen, and old browser builds. Fix those before changing fingerprint settings.

What does the geoip=True warning mean?

With a proxy but without geoip, Camoufox keeps your machine's timezone, locale, geolocation and WebRTC IP, which do not match the proxy's exit. geoip=True looks the exit IP up through the proxy and aligns them. It needs pip install "camoufox[geoip]".

Should I run Camoufox headless?

On Linux, prefer headless="virtual", a headed browser on a private Xvfb display; the docs say plain headless may still be detectable. Set CAMOUFOX_VIRTUAL_DISPLAY_SIZE so the screen is not 1x1, or use headless="virtual-gpu" if the machine has a GPU.

Does Camoufox still use BrowserForge?

No. From camoufox 0.5.7 (October 2026) fingerprints come from fpgen, and BrowserForge is no longer a dependency. Import Screen from camoufox.fingerprints and pass os and screen constraints.

Can Camoufox solve Cloudflare Turnstile by itself?

No. Its docs say the browser makes automation hard to fingerprint but does not solve a captcha already on screen. A clean setup often passes non-interactive checks; when it does not, you need a solver that returns the token.

How do I use a Turnstile token from NSLSolver in Camoufox?

Read data-sitekey from the page, request a turnstile token (about 250 ms, $0.80 per 1,000), set it in the cf-turnstile-response field from the isolated world, and call the site's callback in the main world with main_world_eval=True and the mw: prefix. Submit within 300 seconds.

Camoufox gets you to the widget. Get the token in one call.

Turnstile tokens in about 250 ms, cf_clearance for full-page challenges. Free credit with Google, Gmail or Proton sign-up, no card, only successful solves billed.