PHPackages                             afromansr/laravel-math-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. [Utility &amp; Helpers](/categories/utility)
4. /
5. afromansr/laravel-math-captcha

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

afromansr/laravel-math-captcha
==============================

A laravel framework math-captcha package

v1.0(5y ago)12.5kMITPHPPHP &gt;=5.6

Since Oct 1Pushed 5y ago1 watchersCompare

[ Source](https://github.com/afromanSR/laravel-math-captcha)[ Packagist](https://packagist.org/packages/afromansr/laravel-math-captcha)[ RSS](/packages/afromansr-laravel-math-captcha/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

Laravel Math Captcha
====================

[](#laravel-math-captcha)

A simple math-captcha based on [Laravel Simple Captcha](https://laravelarticle.com/laravel-simple-captcha)
Captcha is the most used technique for preventing spam in form submission. The Laravel Math Captcha package will help you to prevent spam form submission. It's a really simple and lightweight Laravel package for captcha.

### Features of Laravel Math Captcha

[](#features-of-laravel-math-captcha)

- Lightweight
- Simple &amp; easy to use
- Support Laravel 5, 6
- Captcha validation rules
- Customizable math operation

#### Installation

[](#installation)

Use \[Composer\] to install the package:

```
$ composer require afromansr/laravel-math-captcha

```

### Usage

[](#usage)

Use the `getCaptchaBox` method, In the form where you need to add captcha.

```
{!!getCaptchaBox()!!}
```

Optional: You can change the captcha answer input box name. By default, it is `_answer`

```
{!!getCaptchaBox('txtAnswer')!!}
```

Example

```

    @csrf

        Name

        E-mail

    {!!getCaptchaBox()!!}

    Submit

```

**Custom Captcha Box**

For adjusting the captcha box in your markup, you can make the captcha box using the `getCaptchaQuestion` method.

```
Captcha
{{getCaptchaQuestion()}}

```

**Custom Captcha Math Operation**

By default, captcha will auto generate math questions with random math operators from addition, subtraction or multiplication. To customise this setting, you need to publish the config file.

```
$ php artisan vendor:publish --tag=captcha-config

```

### Validation

[](#validation)

Use `math_captcha` validation rules where you handle the request.

```
public function handleForm(Request $request)
{
     $this->validate( $request, [
         '_answer'=>'required|simple_captcha'
     ]);
}
```

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity19

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity49

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.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

2049d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/43d31d0a76c5eac7974f155931e3cba6360a5d5e82dce6bd3d173a9fe69fbc36?d=identicon)[afromansr](/maintainers/afromansr)

---

Top Contributors

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

---

Tags

captchalaravel-math-captchamath-captcha

### Embed Badge

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

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

###  Alternatives

[butschster/meta-tags

The most powerful and extendable tools for managing SEO Meta Tags in your Laravel project

628730.7k2](/packages/butschster-meta-tags)

PHPackages © 2026

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