Overview
Google Enterprise reCAPTCHA is a premium version of reCAPTCHA that provides advanced bot protection, enhanced analytics, and enterprise-grade support. It’s designed for high-traffic applications that require robust security and detailed insights.To use Enterprise reCAPTCHA, you need to sign up for Google Cloud and create an Enterprise reCAPTCHA key.
Key Differences from Standard reCAPTCHA
Enhanced security
Enhanced security
Enterprise reCAPTCHA uses more sophisticated machine learning models to detect bots and provides better protection against automated attacks.
Advanced analytics
Advanced analytics
Get detailed insights into traffic patterns, bot detection accuracy, and user behavior through the Google Cloud Console.
Risk-based scoring
Risk-based scoring
Instead of a simple pass/fail, Enterprise reCAPTCHA provides risk scores (0.0 to 1.0) that you can use to make nuanced decisions about user verification.
Custom rules and actions
Custom rules and actions
Define custom security policies, create allowlists/denylists, and configure automated actions based on risk scores.
SLA and support
SLA and support
Enterprise customers receive SLA guarantees and dedicated technical support from Google.
Configuration
To use Enterprise reCAPTCHA with react-google-recaptcha, set theenterprise option to true in the global recaptchaOptions before your component mounts:
Complete Example
Here’s a complete example of using Enterprise reCAPTCHA:Backend Verification
With Enterprise reCAPTCHA, the backend verification is slightly different. You need to use the Enterprise API endpoint:You’ll need to install the
@google-cloud/recaptcha-enterprise package and set up Google Cloud authentication.Using with recaptcha.net
You can combine Enterprise reCAPTCHA with theuseRecaptchaNet option:
recaptcha.net instead of google.com:
https://recaptcha.net/recaptcha/enterprise.js
Script URLs
When you enable Enterprise mode, the library automatically loads the correct script:- Standard Enterprise
- Enterprise with recaptcha.net
You don’t need to manually manage these URLs - the library handles it automatically based on your
window.recaptchaOptions configuration.Risk Score Interpretation
Enterprise reCAPTCHA provides a risk score from 0.0 to 1.0:- 0.0 - 0.3: Very likely a bot - consider blocking or requiring additional verification
- 0.3 - 0.7: Suspicious - may require additional checks or human review
- 0.7 - 1.0: Likely legitimate - can proceed with normal flow
Best Practices
Troubleshooting
Invalid site key error
Invalid site key error
Make sure you’re using an Enterprise site key, not a standard reCAPTCHA v2 key. Enterprise keys are created in the Google Cloud Console, not the reCAPTCHA Admin Console.
Script not loading
Script not loading
Verify that
window.recaptchaOptions is set before the component renders. If you’re using server-side rendering, ensure this configuration is included in your initial HTML.Backend verification fails
Backend verification fails
Ensure you’ve:
- Installed
@google-cloud/recaptcha-enterprise - Set up Google Cloud authentication
- Used the correct project ID and site key
- Enabled the reCAPTCHA Enterprise API in your Google Cloud project