PHPackages                             radebatz/phprules - 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. radebatz/phprules

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

radebatz/phprules
=================

PHP Rules is a rule engine that models formal propositional logic.

112223[2 issues](https://github.com/php-rules/php-rules/issues)PHP

Since Oct 20Pushed 9y ago5 watchersCompare

[ Source](https://github.com/php-rules/php-rules)[ Packagist](https://packagist.org/packages/radebatz/phprules)[ RSS](/packages/radebatz-phprules/feed)WikiDiscussions master Synced 4d ago

READMEChangelogDependenciesVersions (1)Used By (0)

PHP Rules
=========

[](#php-rules)

[![Build Status](https://camo.githubusercontent.com/124d8bd11eadcc592aa97e99bb83dc895f2fadf7fe1253b8bc52c4c4e050622f/68747470733a2f2f7472617669732d63692e6f72672f4465724d616e6f4d616e6e2f70687072756c65732e706e67)](https://travis-ci.org/DerManoMann/phprules)[![Coverage Status](https://camo.githubusercontent.com/b5edfbb527804f4715d15010f1813b889d48fb0bff4efe7c966bae07008f9138/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f4465724d616e6f4d616e6e2f70687072756c65732f62616467652e706e67)](https://coveralls.io/r/DerManoMann/phprules)

PHPRules is a PHP 5.3 fork of the [php-rules](http://www.swindle.net/php-rules/) project.

Getting started
---------------

[](#getting-started)

"PHP Rules is a rule engine that models formal propositional logic. It allows you to separate conditional logic from source code and database triggers in a reusable package, where explicit rules can be independently defined and managed."

[...more](http://www.swindle.net/php-rules/tutorials/getting-started)

New Features
------------

[](#new-features)

- simplified rule syntax using `BOOL`/`VAR` to indicate propositions/variables
- refactored rule/context loading that should make it easier to integrate into different storage systems
- `IN` operator to evaluate if a value exists in a list
- support to dynamically add operators
- `CompositeRule` class to allow to pragmatically create nested rules

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

[](#installation)

The recommended way to install phprules is [through composer](http://getcomposer.org). Just create a `composer.json` file and run the `php composer.phar install` command to install it:

```
{
    "require": {
        "radebatz/phprules": "1.0.*@dev"
    }
}

```

Alternatively, you can download the [`phprules.zip`](https://github.com/DerManoMann/phprules/archive/master.zip) file and extract it.

License
-------

[](#license)

PHPRules is licensed under both the MIT and GPL 2.0 licenses.

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance16

Infrequent updates — may be unmaintained

Popularity20

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 75% 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/58fc8faf924fe63e767e726dd23888bda8c2b42b4b28c33243bcfa31078318c7?d=identicon)[DerManoMann](/maintainers/DerManoMann)

---

Top Contributors

[![DerManoMann](https://avatars.githubusercontent.com/u/47783?v=4)](https://github.com/DerManoMann "DerManoMann (6 commits)")[![holtkamp](https://avatars.githubusercontent.com/u/776405?v=4)](https://github.com/holtkamp "holtkamp (2 commits)")

### Embed Badge

![Health badge](/badges/radebatz-phprules/health.svg)

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

###  Alternatives

[laravel-frontend-presets/now-ui-dashboard

Laravel 11.x Front-end preset for now ui dashboard

22318.3k](/packages/laravel-frontend-presets-now-ui-dashboard)[artesaos/cidadesbr

537.7k](/packages/artesaos-cidadesbr)

PHPackages © 2026

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