PHPackages                             johntaa/captcha - 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. johntaa/captcha

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

johntaa/captcha
===============

Captcha for Laravel PHP Framework L4 and L5

65.3k1PHP

Since Sep 11Pushed 10y ago2 watchersCompare

[ Source](https://github.com/Johntaa/laravel-captcha)[ Packagist](https://packagist.org/packages/johntaa/captcha)[ RSS](/packages/johntaa-captcha/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependenciesVersions (2)Used By (0)

Captcha for Laravel 4.\*
========================

[](#captcha-for-laravel-4)

For Laravel 5 change to branch masterl5
---------------------------------------

[](#for-laravel-5-change-to-branch-masterl5)

It is just a copy of  but maintained to serve Laravel framework

A simple [Laravel framework](http://laravel.com/) service provider for including the [Captcha for Laravel framework](https://github.com/johntaa/captcha).

Preview
-------

[](#preview)

[![Preview](https://camo.githubusercontent.com/d82ebc3307d2dee86766a9cc3b8d044546dc0bdd4ca3f722b3618f35191c379e/687474703a2f2f692e696d6775722e636f6d2f6b665859686c6b2e6a70673f31)](https://camo.githubusercontent.com/d82ebc3307d2dee86766a9cc3b8d044546dc0bdd4ca3f722b3618f35191c379e/687474703a2f2f692e696d6775722e636f6d2f6b665859686c6b2e6a70673f31)

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

[](#installation)

### Note: This Script Requires GD extension to be installed

[](#note-this-script-requires-gd-extension-to-be-installed)

The Captcha Service Provider can be installed via [Composer](http://getcomposer.org) by requiring the `mews/captcha` package and setting the `minimum-stability` to `dev` (required for Laravel 4.1) in your project's `composer.json`.

```
{
    "require": {
        "laravel/framework": "4.*",
        "johntaa/captcha": "dev-master"
    },
    "minimum-stability": "dev"
}
```

Update your packages with `composer update` or install with `composer install`.

Usage
-----

[](#usage)

To use the Captcha Service Provider, you must register the provider when bootstrapping your Laravel application. There are essentially two ways to do this.

Find the `providers` key in `app/config/app.php` and register the Captcha Service Provider.

```
    'providers' => array(
        // ...
        'Johntaa\Captcha\CaptchaServiceProvider',
    )
```

Find the `aliases` key in `app/config/app.php`.

```
    'aliases' => array(
        // ...
        'Captcha' => 'Johntaa\Captcha\Facades\Captcha',
    )
```

Configuration
-------------

[](#configuration)

To use your own settings, publish config.

`$ php artisan config:publish johntaa/captcha`

Example Usage
-------------

[](#example-usage)

```
    // [your site path]/app/routes.php

    Route::any('/captcha-test', function()
    {

        if (Request::getMethod() == 'POST')
        {
            $rules =  array('captcha' => array('required', 'captcha'));
            $validator = Validator::make(Input::all(), $rules);
            if ($validator->fails())
            {
                echo 'Incorrect!';
            }
            else
            {
                echo 'Matched :)';
            }
        }

        $content = Form::open(array(URL::to(Request::segment(1))));
        $content .= '' . HTML::image(Captcha::img(), 'Captcha image') . '';
        $content .= '' . Form::text('captcha') . '';
        $content .= '' . Form::submit('Check') . '';
        $content .= '' . Form::close() . '';
        return $content;

    });
```

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity23

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity43

Maturing project, gaining track record

 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/a606a511f04f7a34c009408349ef56d0c756f2e49d8c0a69fecfa063dd4d9fa1?d=identicon)[Johntaa](/maintainers/Johntaa)

---

Top Contributors

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

### Embed Badge

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

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

###  Alternatives

[namshi/jose

JSON Object Signing and Encryption library for PHP.

1.8k99.6M101](/packages/namshi-jose)[league/oauth1-client

OAuth 1.0 Client Library

99698.8M106](/packages/league-oauth1-client)[bezhansalleh/filament-shield

Filament support for `spatie/laravel-permission`.

2.8k2.9M88](/packages/bezhansalleh-filament-shield)[gesdinet/jwt-refresh-token-bundle

Implements a refresh token system over Json Web Tokens in Symfony

70516.4M35](/packages/gesdinet-jwt-refresh-token-bundle)[league/oauth2-google

Google OAuth 2.0 Client Provider for The PHP League OAuth2-Client

41721.2M118](/packages/league-oauth2-google)[illuminate/auth

The Illuminate Auth package.

9327.3M1.0k](/packages/illuminate-auth)

PHPackages © 2026

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