PHPackages                             mathsgod/jwt-recaptcha - 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. mathsgod/jwt-recaptcha

ActiveLibrary

mathsgod/jwt-recaptcha
======================

using json web token for recaptcha, without session, without database

2.0.1(1y ago)17[1 PRs](https://github.com/mathsgod/jwt-recaptcha/pulls)MITPHPPHP &gt;=8.0.0CI passing

Since Apr 8Pushed 1y ago1 watchersCompare

[ Source](https://github.com/mathsgod/jwt-recaptcha)[ Packagist](https://packagist.org/packages/mathsgod/jwt-recaptcha)[ RSS](/packages/mathsgod-jwt-recaptcha/feed)WikiDiscussions master Synced today

READMEChangelog (4)Dependencies (2)Versions (6)Used By (0)

jwt-recaptcha
=============

[](#jwt-recaptcha)

using jwt for recaptcha in php

Server generate hash
--------------------

[](#server-generate-hash)

```
$secret="your secret key";

$re = new ReCaptcha($secret);
$hash = $re->hash();

echo $hash["token"]; //token sent to user, use for verify later
echo $hash["image"]; //recaptcha image
```

Server verify recaptcha code
----------------------------

[](#server-verify-recaptcha-code)

```
$re = new ReCaptcha($secret);
$code;//get from user
$token;//get from user sent before

if($re->verify($code,$token)){
    //correct code
}else{
    //incorrect code
}
```

### Demo

[](#demo)

```
$re = new ReCaptcha($secret,  [
    "charset" => "1234567890",
    "code_length" => 4,
    "num_lines" => 1,
    "perturbation" => 0.5
]);

$hash = $re->hash();
$image_src = $hash["image"];
```

[![](https://raw.githubusercontent.com/mathsgod/jwt-recaptcha/refs/heads/master/demo/demo.png)](https://raw.githubusercontent.com/mathsgod/jwt-recaptcha/refs/heads/master/demo/demo.png)

###  Health Score

33

—

LowBetter than 75% of packages

Maintenance42

Moderate activity, may be stable

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity65

Established project with proven stability

 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.

###  Release Activity

Cadence

Every ~587 days

Total

4

Last Release

461d ago

Major Versions

1.0.1 → 2.0.02024-11-28

PHP version history (2 changes)1.0.0PHP &gt;=7.0

2.0.0PHP &gt;=8.0.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/30f25555e58060ace793b731c172c739d45e9506154c9611990d2f985f61652b?d=identicon)[mathsgod](/maintainers/mathsgod)

---

Top Contributors

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

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/mathsgod-jwt-recaptcha/health.svg)

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

###  Alternatives

[laravel/socialite

Laravel wrapper around OAuth 1 &amp; OAuth 2 libraries.

5.7k96.9M674](/packages/laravel-socialite)[laravel/passport

Laravel Passport provides OAuth2 server support to Laravel.

3.4k85.0M531](/packages/laravel-passport)[google/auth

Google Auth Library for PHP

1.4k272.7M162](/packages/google-auth)[kreait/firebase-php

Firebase Admin SDK

2.4k39.7M72](/packages/kreait-firebase-php)[shopify/shopify-api

Shopify API Library for PHP

4634.8M16](/packages/shopify-shopify-api)[thenetworg/oauth2-azure

Azure Active Directory OAuth 2.0 Client Provider for The PHP League OAuth2-Client

2509.6M48](/packages/thenetworg-oauth2-azure)

PHPackages © 2026

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