Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Recaptcha2 Bundle

Recaptcha2 Bundle Laravel Package

beelab/recaptcha2-bundle

Symfony bundle that integrates Google reCAPTCHA v2 into your app. Provides easy configuration, form integration, and server-side verification support, with documentation and tests included. Released under the LGPL license.

View on GitHub
Deep Wiki
Context7

:computer: Symfony bundle for Google Recaptcha2

Frequently asked questions about Recaptcha2 Bundle
Can I use this bundle directly in a Laravel project without Symfony?
No, this bundle is designed for Symfony and won’t work natively in Laravel due to differences in form handling, dependency injection, and templating (Twig vs. Blade). You’d need a custom wrapper or alternative package.
What Laravel alternatives exist for reCAPTCHA v2 integration?
Consider dedicated Laravel packages like `beberlei/laravel-recaptcha` or the official `google/recaptcha` PHP SDK. These avoid Symfony dependencies and integrate seamlessly with Laravel’s validation and Blade templates.
Does this bundle support reCAPTCHA v3 (risk scoring) or only v2?
This bundle only supports reCAPTCHA v2 (checkbox/invisible). For v3’s dynamic risk scoring, you’d need a different solution, like the Google SDK or a Laravel-native package that explicitly supports v3.
How do I configure site/secret keys in Laravel if I use this bundle?
The bundle expects Symfony’s `config/packages/beelab_recaptcha2.yaml`. In Laravel, you’d need to manually map these to `.env` or `config/recaptcha.php`, as the bundle doesn’t support Laravel’s configuration system natively.
Will this bundle work with Laravel’s FormRequest validation?
No, the bundle’s validation relies on Symfony’s `Validator` and `FormType`. You’d need to replicate its logic in Laravel using `FormRequest` rules or a custom validator, which isn’t straightforward.
Can I use this bundle in Laravel’s Blade templates for rendering the reCAPTCHA widget?
No, the bundle assumes Twig for rendering. In Laravel, you’d need to manually include the reCAPTCHA HTML snippet via JavaScript or create a custom Blade directive to replicate its widget output.
Is there a way to bypass reCAPTCHA validation in Laravel tests (like Symfony’s test mode)?
The bundle’s test-mode bypass isn’t compatible with Laravel’s testing framework. You’d need to mock the HTTP client or override validation logic in your test cases to simulate reCAPTCHA responses.
Does this bundle add significant overhead to my Laravel project?
Yes, it introduces Symfony dependencies (e.g., `symfony/form`, `symfony/validator`), increasing bundle size and potential conflicts. For minimalism, the Google SDK or a Laravel-native package is preferable.
How often is this bundle updated, and is it future-proof?
The last release was in May 2026, and it focuses solely on reCAPTCHA v2. If Google deprecates v2, this bundle may become obsolete. For long-term use, prioritize solutions supporting v3 or the latest reCAPTCHA APIs.
Can I use this bundle for high-risk forms (e.g., payments, admin actions) in Laravel?
Only if you’re willing to build a wrapper to adapt Symfony’s validation to Laravel’s ecosystem. Otherwise, use a Laravel-native package or the Google SDK, which offer direct integration with Laravel’s validation and security layers.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
yandex/translate-api
voku/simple_html_dom
league/flysystem-vfs
bkwld/upchuck
filament/spatie-laravel-tags-plugin
capell-app/block-library
axium/identity
cetria/laravel-dummy-models
cetria/reflection-helper
agropredict/sso-auth-bundle
evolvestudio/spam-protection
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony
develia/geo-bundle
dreamzy/livewire-charts
touchestate-sdk/php-sdk
22h/doctrine-garbage-collection-bundle
agtp/agtp-php