PHPackages                             mlk9/captcha-laravel - 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. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. mlk9/captcha-laravel

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

mlk9/captcha-laravel
====================

image captcha for Laravel 9+

v3.1.1(2y ago)41.1k1MITPHPPHP &gt;=7.4

Since Sep 6Pushed 2y ago1 watchersCompare

[ Source](https://github.com/mlk9/captcha-laravel)[ Packagist](https://packagist.org/packages/mlk9/captcha-laravel)[ RSS](/packages/mlk9-captcha-laravel/feed)WikiDiscussions main Synced 3w ago

READMEChangelog (10)Dependencies (7)Versions (15)Used By (0)

Captcha Laravel
===============

[](#captcha-laravel)

image captcha for Laravel

- works with session
- generates image your custom

Persian Docs for V2 :

Installation
============

[](#installation)

you can install this package via composer

```
composer require mlk9/captcha-laravel
```

then publish vendor

```
php artisan vendor:publish --tag=captcha-laravel
```

Documents
=========

[](#documents)

Configure
---------

[](#configure)

- type (array , \[char, math\])
- backgrounds (array)
- char (string)
- length (int)
- font (string|array)
- colors (array)
- width (int)
- height (int)
- type\_hash (\[laravel, sha256, md5\])

Generate captcha simple
-----------------------

[](#generate-captcha-simple)

you can use component:

```

  //via refresh
```

or create custom like this:

```

   {{ __('captcha.captcha') }}

```

Validation
----------

[](#validation)

You can use `captcha` rule in your validations

```
Illuminate\Support\Facades\Validator::validate($request->all(),
    ["captchaField"=>"captcha"]
);
```

#### also

[](#also)

you can add middleware `captcha` to your routes or controllers

and the third way use `isValid(string: entry)` from `\Mlk9\Captcha\Facades\Captcha::class` for example :

```
if(!\Mlk9\Captcha\Facades\Captcha::isValid($request->captcha))
{
    return back()->withErrors('Wrong Captcha');
}
```

notice for v2
-------------

[](#notice-for-v2)

if you get error for font you can replace in config `'font' => public_path('vendor/captcha/fonts/tahoma.ttf'),`

###  Health Score

30

—

LowBetter than 62% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity19

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 93.1% 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 ~64 days

Recently: every ~169 days

Total

14

Last Release

921d ago

Major Versions

v0.0.1 → v1.0.02021-09-06

v1.1.5 → v2.0.12022-02-16

v2.0.3 → v3.0.12023-12-24

PHP version history (2 changes)v0.0.1PHP &gt;=7.1.3

v3.0.1PHP &gt;=7.4

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/68475615?v=4)[Mohammad Maleki](/maintainers/mlk9)[@mlk9](https://github.com/mlk9)

---

Top Contributors

[![mlk9](https://avatars.githubusercontent.com/u/68475615?v=4)](https://github.com/mlk9 "mlk9 (54 commits)")[![hamidreza2005](https://avatars.githubusercontent.com/u/66130204?v=4)](https://github.com/hamidreza2005 "hamidreza2005 (4 commits)")

---

Tags

captchalaravellaravel-packagepackagerecaptcha

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StyleLaravel Pint

Type Coverage Yes

### Embed Badge

![Health badge](/badges/mlk9-captcha-laravel/health.svg)

```
[![Health](https://phpackages.com/badges/mlk9-captcha-laravel/health.svg)](https://phpackages.com/packages/mlk9-captcha-laravel)
```

###  Alternatives

[directorytree/ldaprecord-laravel

LDAP Authentication &amp; Management for Laravel.

5752.3M18](/packages/directorytree-ldaprecord-laravel)[illuminate/auth

The Illuminate Auth package.

10528.2M1.2k](/packages/illuminate-auth)[intervention/image-laravel

Laravel Integration of Intervention Image

1588.9M182](/packages/intervention-image-laravel)[hasinhayder/tyro-dashboard

Tyro Dashboard - Beautiful admin dashboard for managing Tyro roles, privileges, users, and settings

5443.8k](/packages/hasinhayder-tyro-dashboard)[fleetbase/core-api

Core Framework and Resources for Fleetbase API

1235.9k20](/packages/fleetbase-core-api)

PHPackages © 2026

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