PHPackages                             simfatic/php-form-validator - 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. simfatic/php-form-validator

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

simfatic/php-form-validator
===========================

A PHP Library for Self-Documenting Form Validations

1.0.1(9y ago)8362MITPHPPHP &gt;=5.4.3

Since Apr 24Pushed 4y ago3 watchersCompare

[ Source](https://github.com/simfatic/php-form-validator)[ Packagist](https://packagist.org/packages/simfatic/php-form-validator)[ RSS](/packages/simfatic-php-form-validator/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependencies (1)Versions (3)Used By (0)

PHPFormValidator
================

[](#phpformvalidator)

A PHP Library for 'self-documenting' server side Form Validations.

A typical usage would be like this:

```
use FormGuide\PHPFormValidator\FormValidator;

$validator = FormValidator::create();

$validator->fields(['name','email'])->areRequired()->maxLength(50);
$validator->field('email')->isEmail();

if(!$validator->test($_POST))
{
	return json_encode($validator->getErrors(true));
}
```

Installation using composer
---------------------------

[](#installation-using-composer)

```
composer require FormGuide/PHPFormValidator

```

Declaring validations for single fields
---------------------------------------

[](#declaring-validations-for-single-fields)

```
$validator->field('email')->isEmail()->isRequired();
```

Declaring validations for multiple fields
-----------------------------------------

[](#declaring-validations-for-multiple-fields)

```
$validator->fields(['name','email'])->areRequired()->maxLength(50);
```

This is equivalent to:

```
$validator->field('name')->isRequired()->maxLength(50);

$validator->field('email')->isRequired()->maxLength(50);
```

###  Health Score

29

—

LowBetter than 59% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity59

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

Every ~16 days

Total

2

Last Release

3295d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/c0010a8bac8b7b4b62fe73df7331863ba4d6b4e62e958fe6febced434af3ddfe?d=identicon)[prasanthmj](/maintainers/prasanthmj)

---

Top Contributors

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

---

Tags

form validationPHP form validation

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/simfatic-php-form-validator/health.svg)

```
[![Health](https://phpackages.com/badges/simfatic-php-form-validator/health.svg)](https://phpackages.com/packages/simfatic-php-form-validator)
```

###  Alternatives

[pearl/lumen-request-validate

Lumen doesn't have form request validator seperatly. This package helps developers to segregate the validation layer from the controller to a separate dedicated class

45390.3k2](/packages/pearl-lumen-request-validate)[bitapps/wp-validator

WordPress Validation and Sanitization Library

127.4k1](/packages/bitapps-wp-validator)

PHPackages © 2026

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