PHPackages                             tobischulz/trashmail-checker - 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. tobischulz/trashmail-checker

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

tobischulz/trashmail-checker
============================

Validates email addresses of known trashmail providers to keep away untrusted registrations.

1.2.0(4y ago)234MITPHPPHP ^7.2|^8.0

Since Nov 20Pushed 4y ago1 watchersCompare

[ Source](https://github.com/tobischulz/trashmail-checker)[ Packagist](https://packagist.org/packages/tobischulz/trashmail-checker)[ RSS](/packages/tobischulz-trashmail-checker/feed)WikiDiscussions master Synced 6d ago

READMEChangelogDependencies (2)Versions (4)Used By (0)

Trashmail Checker
=================

[](#trashmail-checker)

[![Latest Version on Packagist](https://camo.githubusercontent.com/7b2ef5b3d24e6d4897c77e0edd78e1c87bf761099f8c4fa6e4d5a9bda808bbfe/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f746f6269736368756c7a2f74726173686d61696c2d636865636b65722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/tobischulz/trashmail-checker)[![Total Downloads](https://camo.githubusercontent.com/ebd49b3f8f3f7d00493fc67e0eb57cddc6085905b5b6fec7333ee94155ec5572/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f746f6269736368756c7a2f74726173686d61696c2d636865636b65722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/tobischulz/trashmail-checker)

Validates email addresses of known trashmail/temporary mail/disposable mail providers, managed by your own database, to keep away unserious registrations.

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

[](#installation)

You can install the package via composer:

```
composer require tobischulz/trashmail-checker
```

Publish all required assets:

```
php artisan vendor:publish --provider=TobiSchulz\TrashmailChecker\TrashmailCheckerServiceProvider
```

Migrate your database:

```
php artisan migrate
```

Usage
-----

[](#usage)

### Validation Rule

[](#validation-rule)

```
use TobiSchulz\TrashmailChecker\Rules\NoTrashmail;

class ValidateEmailController extends Controller
{
    public function __invoke(Request $request)
    {
        $request->validate([
            'email' => ['required', 'email', 'bail', new NoTrashmail],
        ]);
    }
}
```

### Facade

[](#facade)

```
use TobiSchulz\TrashmailChecker\Facade\TrashmailChecker;

TrashmailChecker::check('taylor@trashmail.com');
```

### Configuration

[](#configuration)

TrashmailChecker would let you disable the email check in development (env= local) by setting key `TRASHMAIL_IN_DEVELOPMENT` to `false` in your .env file.

```
TRASHMAIL_IN_DEVELOPMENT=false

```

### Testing

[](#testing)

```
composer test
```

### Changelog

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

### Security

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Tobias Schulz](https://github.com/:tobischulz)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity64

Established project with proven stability

 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 ~301 days

Total

3

Last Release

1767d ago

PHP version history (2 changes)1.0.0PHP ^7.2

1.2.0PHP ^7.2|^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/89fff95b130891f483965b2bcf41aa9d6e2be5b9c60050acf9d6f936f1b7b282?d=identicon)[tobiasschulz](/maintainers/tobiasschulz)

---

Top Contributors

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

---

Tags

disposable-emailsemail-validationlaravelruletrashmailvalidationlaraveldisposable emailsvalidation ruletrashmailwegwerfemaildetect suspicious email addresses

### Embed Badge

![Health badge](/badges/tobischulz-trashmail-checker/health.svg)

```
[![Health](https://phpackages.com/badges/tobischulz-trashmail-checker/health.svg)](https://phpackages.com/packages/tobischulz-trashmail-checker)
```

###  Alternatives

[askedio/laravel5-profanity-filter

A Vendor Package Example

52354.1k](/packages/askedio-laravel5-profanity-filter)[laravel-validation-rules/us-state

Validate US States and Canada Provinces

16172.7k](/packages/laravel-validation-rules-us-state)[pacerit/laravel-polish-validation-rules

Simple Polish Validation rules for Laravel and Lumen framework

1449.9k](/packages/pacerit-laravel-polish-validation-rules)[laravel-validation-rules/ip

Validate if an ip address is public or private.

1629.7k](/packages/laravel-validation-rules-ip)[janvince/smallcontactform

Simple but flexible multi language contact form builder with custom fields, validation and passive antispam

307.4k](/packages/janvince-smallcontactform)[basillangevin/laravel-data-json-schemas

Transforms Spatie Data objects into JSON Schemas with built-in validation

1312.2k1](/packages/basillangevin-laravel-data-json-schemas)

PHPackages © 2026

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