[ Web Proxy ]
URL:
Viewing: https://developers.cloudflare.com/turnstile/migration/recaptcha/ [Back]  [Original]

Migrate from reCAPTCHA Cloudflare Turnstile docsSkip to content
SearchCtrlKLog in
  1. Home
  2. /Turnstile
  3. /Migration
  4. /Migrate from reCAPTCHA

Migrate from reCAPTCHA

Last updated May 5, 2026Copy as MarkdownView as MarkdownAgent setup
OverviewClient-side integrationServer-side integration

If you are using reCAPTCHA today, you can switch seamlessly to Cloudflare Turnstile by following the step-by-step guide below to assist with the upgrade process.

To complete the migration, you must obtain the sitekey and secret key.

Note

Turnstile migration is currently compatible up to reCAPTCHA v2.

Client-side integration

  1. Update the client-side integration by inserting the Turnstile script snippet in your HTML's <head> element.

    Turnstile script snippethtml
    <script
    	src="https://challenges.cloudflare.com/turnstile/v0/api.js?compat=recaptcha"
    	async
    	defer
    ></script>

    Note

    Adding ?compat=recaptcha runs Turnstile in compatibility mode, which enables the following features:

    • implicit rendering for reCAPTCHA
    • g-recaptcha-response input name for forms
    • register the Turnstile API as grecaptcha
  2. Locate the grecaptcha.render() calls and replace the sitekey with your Turnstile sitekey.

    Note

    Turnstile supports:

    • the render() call
    • reCAPTCHA v2 invisible mode with the execute() call

Server-side integration

Update the server-side integration by replacing the Siteverify URL.

Replace https://www.google.com/recaptcha/api/siteverify with the following:

https://challenges.cloudflare.com/turnstile/v0/siteverify

Differences to reCAPTCHA's Siteverify

reCAPTCHA supports GET requests using query parameters, such as GET /siteverify?response=<response>&secret=<secret>.

Turnstile's Siteverify endpoint does not support this and only accepts POST requests with a FormData or JSON body.

Refer to server-side validation for more information.

PreviousOverviewNextMigrate from hCaptcha

Was this helpful?

YesNo
Edit pageReport issue
[]

Web Proxy Viewer  |  New URL  |  Original Page