Cloudflare Turnstile CAPTCHA Solver
Solve Cloudflare Turnstile CAPTCHA challenges through AceDataCloud's captcha API. Submit the site key and target URL to receive a valid cf-turnstile-response token.
Setup: See authentication for token setup.
Quick Start
curl -X POST https://api.acedata.cloud/captcha/token/turnstile \
-H "Authorization: ******" \
-H "Content-Type: application/json" \
-d '{
"website_key": "0x4AAAAAAADnPIDROrmt1Wwj",
"website_url": "https://react-turnstile.vercel.app"
}'
A successful synchronous response:
{
"token": "0.mNQ2f9uP6mQ0y3H5Q8bqO7iM...",
"started_at": 1784885653.0,
"finished_at": 1784885665.0,
"elapsed": 12.4
}
Use the returned token as the cf-turnstile-response value when submitting forms to the target site. The token is single-use with a ~120s validity — use it within 60s.
How to Find website_key
- Open the target page in a browser and press F12 to open DevTools
- In the Elements panel, search for
cf-turnstile - Find the container element — the
data-sitekeyattribute value is thewebsite_key
Parameters
| Parameter | Required | Description |
|---|---|---|
website_key |
✓ | The Turnstile site key (data-sitekey) from the target page |
website_url |
✓ | The full URL of the page containing the Turnstile widget |
action |
Custom action value — only needed when the target page sets a custom action |
|
cdata |
Custom cData value — only needed when the target page sets a custom cData |
|
async |
When true, return immediately with a task_id; poll POST /captcha/tasks to retrieve the token |
Response Fields
| Field | Description |
|---|---|
token |
The solved Turnstile token to submit as cf-turnstile-response |
started_at |
ISO-8601 timestamp when solving began |
finished_at |
ISO-8601 timestamp when solving completed |
elapsed |
Total solving time in seconds |
Async Mode
Pass async: true to return a task_id immediately instead of blocking:
POST /captcha/token/turnstile
{
"website_key": "0x4AAAAAAADnPIDROrmt1Wwj",
"website_url": "https://react-turnstile.vercel.app",
"async": true
}
Then poll POST /captcha/tasks with the returned task_id:
POST /captcha/tasks
{"task_id": "<task_id>"}
Async: See async task polling for the full polling contract.
Using the Token
Submit the token to the target site as cf-turnstile-response:
import requests
token = "0.mNQ2f9uP6mQ0y3H5Q8bqO7iM..."
response = requests.post(
"https://react-turnstile.vercel.app",
data={"cf-turnstile-response": token}
)
Gotchas
- Both
website_keyandwebsite_urlare required - The token is single-use and valid for ~120s — use within 60s for best results
actionandcdataare optional and only required when the target site explicitly uses them- You are billed only when a token is successfully solved
- Synchronous mode blocks until the token is ready (typically 10–30s); use
async: truefor non-blocking operation
MCP: See MCP servers for tool-use integration.