PHPackages                             grd/ban-words - 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. grd/ban-words

Abandoned → abandonLibrary[Utility &amp; Helpers](/categories/utility)

grd/ban-words
=============

A simple PHP ban bad words

020PHP

Since Jan 26Pushed 3mo ago1 watchersCompare

[ Source](https://github.com/Gwigzz/banWords)[ Packagist](https://packagist.org/packages/grd/ban-words)[ RSS](/packages/grd-ban-words/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)DependenciesVersions (1)Used By (0)

Simple PHP ban bad words
------------------------

[](#simple-php-ban-bad-words)

Simple and fast PHP ban bad words you want.

You need to set the bad words in `vendor/src/BadWords.php` in array of `list` method.

### Inportant note

[](#inportant-note)

banWords does not and never will prevent XSS or SQL Injection.

#### Require

[](#require)

- PHP &gt;= 7.4
- composer

#### Simple usage

[](#simple-usage)

```
composer require grd/ban-words

```

```
use App\Grd\BanWords\BanWords;

require_once './vendor/autoload.php';

// 1. Initialize
$banWords = new BanWords('hello noob you are bad !');

// very simple
var_dump($banWords->check());

// get true if bad words spotted
$banWords->check()->getSignal();        # return true / false

// get normal characters
$banWords->check()->getCharacters();    # return "hello noob you are bad !"

// get ban words
$banWords->check()->getFilter();        # return "hello *** you are *** !"
```

```
This script is very simple.
You are welcome to improve it !

```

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance53

Moderate activity, may be stable

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity12

Early-stage or recently created project

 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/bd58c0684e338c08c7ee87100aaf342d39d56bec4d863ab2caa9802887d0f08e?d=identicon)[Guillaume RGD](/maintainers/Guillaume%20RGD)

---

Top Contributors

[![Gwigzz](https://avatars.githubusercontent.com/u/84151418?v=4)](https://github.com/Gwigzz "Gwigzz (22 commits)")

### Embed Badge

![Health badge](/badges/grd-ban-words/health.svg)

```
[![Health](https://phpackages.com/badges/grd-ban-words/health.svg)](https://phpackages.com/packages/grd-ban-words)
```

PHPackages © 2026

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