PHPackages                             henriqueramos/recaptcha\_middleware - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Validation &amp; Sanitization](/categories/validation)
4. /
5. henriqueramos/recaptcha\_middleware

ActiveLibrary[Validation &amp; Sanitization](/categories/validation)

henriqueramos/recaptcha\_middleware
===================================

Laravel reCaptcha Middleware it's a Composer package created to help us to validate reCaptcha payloads during the initial steps of request lifecycle.

04[1 PRs](https://github.com/henriqueramos/laravel-recaptcha-middleware/pulls)PHP

Since Jan 13Pushed 5y ago1 watchersCompare

[ Source](https://github.com/henriqueramos/laravel-recaptcha-middleware)[ Packagist](https://packagist.org/packages/henriqueramos/recaptcha_middleware)[ RSS](/packages/henriqueramos-recaptcha-middleware/feed)WikiDiscussions master Synced today

READMEChangelogDependenciesVersions (2)Used By (0)

laravel-recaptcha-middleware
============================

[](#laravel-recaptcha-middleware)

=========

Laravel reCaptcha Middleware it's a Composer package created to help us to validate reCaptcha payloads during the initial steps of request lifecycle.

Installation
------------

[](#installation)

Add the following line to the `require` section of `composer.json`:

```
{
    "require": {
        "henriqueramos/recaptcha_middleware": "dev-master"
    }
}
```

Setup
-----

[](#setup)

1. Run `php artisan vendor:publish --provider="RamosHenrique\reCaptchaMiddleware"`.
2. In your .env, enter your reCAPTCHA private key as value for `RECAPTCHA_MIDDLEWARE_SECRET_KEY` and `RECAPTCHA_MIDDLEWARE_RESPONSE_TYPE` as `json` or `html`.

Usage
-----

[](#usage)

Add into your selected routes the middleware `recaptcha_middleware`.

```
$this->router->post(
    'myProtectedRoute',
    [
        'as' => 'my.protected.route',
        'uses' => 'ProtectedRouteController@necessaryMethod',
    ]
)
->middleware('recaptcha_middleware');
```

###  Health Score

18

—

LowBetter than 8% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/9e40a0e4f71456fa890e44510580c98de67072513aef49e0c8f7b5e5bd918a90?d=identicon)[henriqueramos](/maintainers/henriqueramos)

---

Top Contributors

[![henriqueramos](https://avatars.githubusercontent.com/u/1243634?v=4)](https://github.com/henriqueramos "henriqueramos (4 commits)")

### Embed Badge

![Health badge](/badges/henriqueramos-recaptcha-middleware/health.svg)

```
[![Health](https://phpackages.com/badges/henriqueramos-recaptcha-middleware/health.svg)](https://phpackages.com/packages/henriqueramos-recaptcha-middleware)
```

###  Alternatives

[webmozart/assert

Assertions to validate method input/output with nice error messages.

7.6k894.0M1.2k](/packages/webmozart-assert)[bensampo/laravel-enum

Simple, extensible and powerful enumeration implementation for Laravel.

2.0k15.9M104](/packages/bensampo-laravel-enum)[swaggest/json-schema

High definition PHP structures with JSON-schema based validation

48612.5M73](/packages/swaggest-json-schema)[stevebauman/purify

An HTML Purifier / Sanitizer for Laravel

5325.6M19](/packages/stevebauman-purify)[ashallendesign/laravel-config-validator

A package for validating your Laravel app's config.

217905.3k5](/packages/ashallendesign-laravel-config-validator)[crazybooot/base64-validation

Laravel validators for base64 encoded files

1341.9M8](/packages/crazybooot-base64-validation)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
