What is the Cloudflare challenge page?
You have probably seen it. You open a website and, instead of the site, you get a plain page that says “Just a moment…” or “Verifying you are human. This may take a few seconds.” After a short wait, the real site loads. Sometimes there is a box to tick first.
That page is Cloudflare checking your browser before it lets you in. A real browser passes the check and gets a cookie called cf_clearance. From then on, every request that carries this cookie goes straight to the site.
A script that asks for the page gets the challenge instead, with the status code 403. It never gets the cookie, so it never sees the site. That is the problem this type solves. You ask us for the cookie, and then your script can load the site like a browser that passed the check.
How to solve the Cloudflare challenge with DraxonCloud
- Copy the address of the page that shows “Just a moment…”.
- Pick a proxy, and make sure it keeps the same IP for a few minutes.
- Send both to our API with the type
cloudflare_challenge. - Wait for the answer. It holds the
cf_clearancecookie and the user agent. - Load the site through the same proxy, with that cookie and that user agent.
What you send
website_url: the full address of the protected page, likehttps://shop.example/products. Use the page you actually want to open.proxy(required): your proxy, written asuser:pass@host:port, or with a scheme likehttp://user:pass@host:portorsocks5://user:pass@host:port. We pass the check through this proxy, because the cookie only works from the IP that earned it. We turn the task down if you leave the proxy out.
You don’t need a site key for this type. The page is the whole challenge.
About rotating proxies. Many proxy providers give you a new IP every minute, or even every request. That breaks this flow. The cookie gets tied to one IP, and then your next request comes from another IP, so Cloudflare asks again. Ask your provider for a sticky session and set it to last several minutes. In our own tests, a 1-minute session switched IP during a solve and the cookie was refused. A 10-minute session worked.
What you get back
When the task is solved, the answer has:
solution.cookies:{"cf_clearance": "..."}solution.cookie_header: the same thing, ready to paste into aCookieheader, likecf_clearance=...solution.user_agent: the browser user agent that earned the cookiesolution.token: thecf_clearancevalue on its own
To use it, send every request to the site:
- through the same proxy you gave us,
- with the
cf_clearancecookie, and - with the same
User-Agentwe returned.
If one of the three is different, Cloudflare will likely show the challenge again.
A quick example
Start a task:
curl -s -X POST https://draxon.one/api/captcha/v1/tasks \
-H "Authorization: Bearer $DRAXON_KEY" \
-H "Content-Type: application/json" \
-d '{
"type": "cloudflare_challenge",
"website_url": "https://shop.example/products",
"proxy": "user-session-abc123:[email protected]:8080"
}'
Wait for it in one request:
curl -s -H "Authorization: Bearer $DRAXON_KEY" \
"https://draxon.one/api/captcha/v1/tasks/<id>?wait=60"
The answer looks like this (some fields left out):
{
"status": "solved",
"solution": {
"token": "Cq1BevBXrsMqyd22VGYT6qwW...",
"cookies": {"cf_clearance": "Cq1BevBXrsMqyd22VGYT6qwW..."},
"cookie_header": "cf_clearance=Cq1BevBXrsMqyd22VGYT6qwW...",
"user_agent": "Mozilla/5.0 (iPhone; CPU iPhone OS 18_7 like Mac OS X)..."
}
}
Now load the site with it:
curl -s -x "http://user-session-abc123:[email protected]:8080" \
-H "User-Agent: <solution.user_agent>" \
-H "Cookie: <solution.cookie_header>" \
https://shop.example/products
Challenge or block? Know the difference
Not every Cloudflare page is a challenge. If you see “Sorry, you have been blocked” or “Attention Required!” with a Ray ID, the site’s firewall has blocked that visitor on purpose. There is nothing to pass and no cookie that opens it. Solving won’t help there. A different IP might, or the site may simply not allow automated access.
A real challenge page answers with status 403 and the header cf-mitigated: challenge, and its title is usually “Just a moment…”. That is the page this type is for.
Looking for the small Cloudflare box inside a form instead? That is Cloudflare Turnstile, and it has its own type.
Already using another service?
- CapSolver and Anti-Captcha style:
createTaskwith the typeAntiCloudflareTaskorCloudflareChallengeTask. Give the proxy asproxy(scheme://user:pass@host:port) or asproxyType,proxyAddress,proxyPort,proxyLoginandproxyPassword. The result carriescookies,cookie(cf_clearance=...) anduserAgent. - Point your tool at
https://draxon.one/api/captcha/compatand use your DraxonCloud key as the client key.
All formats are on the Compatible APIs page.
What it costs
You pay for each solved challenge. The current price is in the box at the top of this page and on the pricing page. We hold the price from your balance when the task starts, and charge it only when you get a cookie. If the task fails or runs out of time, you get the full amount back. You never pay twice for one task.
Tips that save you time
- Use one sticky proxy session per cookie. Same IP for the solve and for every request after it.
- Reuse the cookie. One
cf_clearancecovers many requests to the site while it lasts. Don’t solve again for every page. - Keep the user agent the same everywhere. Copy
solution.user_agentinto every request. - Check the status code first. If the site already answers 200, there is no challenge to solve.
- Use
?wait=60. A challenge takes longer than a small widget, so give the wait some room. - Watch for a block page. “Sorry, you have been blocked” is not a challenge, so don’t spend money on it.
Everything else, including code in Python and Node.js, is in the Cloudflare Challenge docs.