Errors & CAPTCHAs

Cloudflare Turnstile: the "verify you are human" box

CAPTCHAs · Cloudflare Turnstile
Published
Made by
Cloudflare
Variants
managed · non-interactive · invisible

What you see

  • Cloudflare Turnstile
  • cf-turnstile-response
  • Verify you are human
  • challenges.cloudflare.com/turnstile/v0/api.js
More error strings (4)
  • class="cf-turnstile"
  • timeout-or-duplicate
  • invalid-input-response
  • turnstile/v0/siteverify

What it means

The site put a Cloudflare bot check inside a form, usually a login, signup or checkout. It runs small tests in your browser and, if you pass, hands the form a one-time pass called a token. No valid token, no submit: your script gets stuck on the box or the server rejects the form.

Why it happens

Turnstile is a widget (a small box on the page), not a wall in front of the whole site. The site doesn’t even need to run through Cloudflare to use it. If you see a full page that says “Just a moment…”, that’s a different check: see Cloudflare “Just a moment…”. Sites on Amazon’s cloud use another widget: AWS WAF CAPTCHA.

The widget comes in 3 modes:

  • Managed (the one Cloudflare recommends): runs the tests, and shows a checkbox only if you look risky.
  • Non-interactive: shows a spinner, never asks you to click.
  • Invisible: nothing on screen at all.

Why your script fails it, most common first:

  1. Your client can’t run JavaScript. The tests are JavaScript: puzzles your computer must solve (proof-of-work), probes of browser features, and checks for browser quirks. requests or curl never runs them, so there’s no token.
  2. Your browser looks automated. Cloudflare’s own docs say Selenium, Cypress and Playwright get detected as bots by Turnstile.
  3. You block what the widget needs. It loads from challenges.cloudflare.com in an iframe (a small page inside the page). Ad blockers, or a scraper that skips scripts to save bandwidth, break it.
  4. Your network looks off. Cloudflare says some VPNs and proxies can make the check fail.
  5. Your token went stale. A token lasts 5 minutes and works once. Reuse it or wait too long and the form fails.

Accessibility: in a 2025 review by a11yboost, Turnstile got the top grade (A+) of all the CAPTCHA systems it compared. Cloudflare says Turnstile meets WCAG 2.2 AA.

Where does the real check happen? Not in your browser. The widget only makes the token. The form sends it to the site’s server, and that server asks Cloudflare if it’s real. That call is named Siteverify.

So you can’t type something into the hidden field and hope. A made-up token comes back as invalid-input-response, and the form fails.

The tests behind the widget are the same tech Cloudflare uses for its full-page check. They just run inside a small box instead of in front of the whole site.

One more reason a new IP may not help: sites on Cloudflare’s Enterprise plans can turn on Ephemeral IDs. That’s a short-lived ID for the device behind each solve, made without cookies. Cloudflare built it to link attempts from the same device even when the IP keeps changing.

Fix it

Avoid triggering it first. Solvers charge per solve.

  1. Make sure it’s Turnstile. Look for a <div class="cf-turnstile"> and the script challenges.cloudflare.com/turnstile/v0/api.js. A full-page block is the other check.
  2. Skip the form if you can. Turnstile guards the form, not every page. If the data you want is readable without logging in or submitting, read it there.
  3. Use a real browser. Playwright, Puppeteer or Selenium let the tests run. Wait for the token before you submit.
  4. Let the widget load. Don’t block challenges.cloudflare.com, its scripts or its iframe.
  5. Look less like a bot. The FuckCaptcha guide says plain Playwright and Puppeteer leak automation traces. It points to patched tools: SeleniumBase UC Mode (it has a uc_gui_click_cf() helper for the checkbox), Camoufox and nodriver.
  6. Test without a proxy or VPN, then try a different one. If the check passes on your home connection, your proxy is the problem.
  7. Submit fast, once. Use the token within 5 minutes. Need to submit again? Get a fresh token.
  8. Still stuck? Use a solver service that lists Turnstile support (A–Z): 2Captcha, CapMonster Cloud, Death By Captcha. You send the page URL and the sitekey (the site’s public widget ID), get a token back, and put it in the form.

Why skip before you solve? Every solve costs money and time, and the token still has to pass the site’s server check.

If you do use a solver, watch the clock. The 5 minutes start when the token is made, not when you get it. So ask for the token right before you submit, not at the start of a long run.

Cloudflare tells site owners to also check the action and hostname that come back with a token. If the widget has a data-action value, pass it to the solver too. 2Captcha’s API has an action field for this.

Some sites also send your IP to Siteverify. 2Captcha offers a task type that solves through your own proxy (TurnstileTask) next to one that uses its own (TurnstileTaskProxyless). Using the same IP for the solve and the submit is the safer choice.

Paste this into your AI

My scraper hits a Cloudflare Turnstile widget on a form, not the full-page "Just a moment..." check.
What I see: <widget state, error code like 110200 or 600xxx, or the Siteverify error, e.g. timeout-or-duplicate>.
Explain in plain words what Turnstile checks.
Then list the likely causes in order, most likely first.
For each cause, give one way to test it and one fix.
My setup: <language + library or browser tool>, <the page URL pattern>,
<headless or headed>, <proxy type or none>, <do I block scripts or iframes to save bandwidth: yes/no>,
<seconds between getting the token and submitting the form>.

Dev details

Spot it in the HTML:

<script src="https://challenges.cloudflare.com/turnstile/v0/api.js" async defer></script>
<div class="cf-turnstile" data-sitekey="<SITEKEY>"></div>
<!-- added by the widget after a pass, sent with the form: -->
<input type="hidden" name="cf-turnstile-response" value="<TOKEN>" />

The iframe matches iframe[src*="challenges.cloudflare.com"], per FuckCaptcha. The JS API is turnstile.render(), turnstile.reset(), turnstile.getResponse() and turnstile.execute().

Token rules (Cloudflare docs):

  • Max 2,048 characters.
  • Valid for 300 seconds (5 minutes).
  • Single use. Reuse checks take time to spread across Cloudflare’s network, so two checks sent very close together may both pass. Don’t build on that.

What the site’s server does with your token:

POST https://challenges.cloudflare.com/turnstile/v0/siteverify
Content-Type: application/x-www-form-urlencoded

secret=<SECRET_KEY>&response=<cf-turnstile-response value>&remoteip=<VISITOR_IP>
{ "success": false, "error-codes": ["invalid-input-response"] }

A pass returns "success": true plus challenge_ts, hostname, action and cdata. Errors the server can get back:

error code means
invalid-input-response token invalid, malformed or expired
timeout-or-duplicate token expired or already used
missing-input-response no token sent
missing-input-secret / invalid-input-secret the site’s own setup is broken
bad-request malformed request
internal-error Cloudflare problem, retry

Widget error codes (shown in the box or passed to the error callback):

code means retry?
110100 / 110110 / 400020 bad or unknown sitekey no
110200 domain not allowed for this sitekey no
110600 challenge timed out (clock wrong or too slow) yes
110620 nobody clicked the checkbox in time yes
200100 clock wrong or challenge cached by a middlebox no
200500 iframe failed to load (is challenges.cloudflare.com blocked?) yes
300* / 600* challenge failed: bot behavior detected yes

Solver flow. For a widget on a normal page, 2Captcha’s docs ask for the page URL and the data-sitekey. You put the returned token in cf-turnstile-response, or pass it to the callback given to turnstile.render. Turnstile on a Cloudflare challenge page is harder. You must catch cData, chlPageData and action from the turnstile.render call, and use the user agent the solver returns.

Testing your own form. Cloudflare’s test keys work on any domain, including localhost:

sitekey does
1x00000000000000000000AA always passes (visible)
2x00000000000000000000AB always fails (visible)
1x00000000000000000000BB always passes (invisible)
2x00000000000000000000BB always fails (invisible)
3x00000000000000000000FF forces the checkbox

Secret keys: 1x0000000000000000000000000000000AA always passes, 2x0000000000000000000000000000000AA always fails, 3x0000000000000000000000000000000AA returns “token already spent”.

Empty hidden field? Check data-execution. By default the token is made when the widget loads. With execute, no token exists until the page itself calls turnstile.execute(), often on the submit click. Read the field too early and you get nothing. data-appearance="interaction-only" hides the box unless a click is needed.

action and cData are labels the site attaches to the widget: up to 32 and 255 characters (letters, digits, _ and -). Both come back from Siteverify.

Turnstile can also give you a cf_clearance cookie. That’s called pre-clearance. It is off by default. When the owner turns it on, passing the widget can also spare you some of the full-page checks on that site. How many depends on the level set: interactive, managed or jschallenge.

Open questions

  • Cloudflare hasn’t said what Siteverify does when the remoteip a site sends doesn’t match the IP that solved the widget.

This matters most if you use a solver. With a proxyless task, the solver makes the token on its own proxies, and you send it to the site from yours. Cloudflare’s docs list remoteip as optional and describe it only as “the visitor’s IP address”. If a mismatch can fail the check, proxyless solving breaks on sites that send it. Until Cloudflare says, solving through the same proxy you submit from is the safer bet.

scrapenews difficulty

61/100 · Complex from 5 of 8 factors

FactorWhat we foundSource
Smallest client that gets througha stealth browserbrowserless.io
Checks stackedTLS fingerprint, JavaScript challenge, proof of work, mouse and behaviourscrapfly.io
Cheapest solver price$1.20 per 1,000 solvesdocs.capsolver.com
Scraper API credits20 Scrapfly credits per solved CAPTCHAscrapfly.io
Steps for a human1 stepdevelopers.cloudflare.com

Our analysis of 5 sourced facts; measured runs replace them as they come. How we rate difficulty

Tools that get past it

ToolPrice
2Captcha: CAPTCHA solving API (reCAPTCHA, Turnstile, image and more), priced per 1,000 solves by CAPTCHA type.$1.00/1k solves
Camoufox: Anti-detect browser built on Firefox that changes fingerprints to look like a real user; works with Playwright.Free
CapMonster Cloud: CAPTCHA solving service priced per 1,000 tokens or images, covering reCAPTCHA, Turnstile, AWS WAF and more.$0.60/1k solves
Death By Captcha: CAPTCHA solving API, priced per 1,000 CAPTCHAs by type, with reCAPTCHA, Turnstile and audio support.$2.89/1k solves
nodriver: Python browser automation without WebDriver or Selenium, from the author of undetected-chromedriver, made to avoid bot checks.Free
Scrapling: Python scraping library from a single request to a full crawl, with stealthy fetchers and selectors that survive page changes.Free
SeleniumBase: Python framework on top of Selenium for testing, crawling and scraping, with a stealth mode against bot checks.Free

Sources

  1. Cloudflare docs: Turnstile developers.cloudflare.com
  2. Cloudflare docs: Turnstile widget modes developers.cloudflare.com
  3. Cloudflare docs: Embed the widget (cf-turnstile-response) developers.cloudflare.com
  4. Cloudflare docs: Validate the token (Siteverify) developers.cloudflare.com
  5. Cloudflare docs: Turnstile widget error codes developers.cloudflare.com
  6. Cloudflare docs: Test sitekeys and secret keys developers.cloudflare.com
  7. Cloudflare docs: Widget configurations (action, cData, execution, appearance) developers.cloudflare.com
  8. Cloudflare docs: Ephemeral IDs developers.cloudflare.com
  9. Cloudflare docs: Clearance (pre-clearance in Turnstile) developers.cloudflare.com
  10. FuckCaptcha (CC0): Cloudflare Turnstile & Challenge field guide github.com
  11. FuckCaptcha: CAPTCHA field guide (39 types) github.com
  12. 2Captcha API docs: Cloudflare Turnstile 2captcha.com
  13. a11yboost: Are CAPTCHA systems failing accessibility? a11yboost.com