PHPackages                             idf/laravel-real-email-validation - 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. [Mail &amp; Notifications](/categories/mail)
4. /
5. idf/laravel-real-email-validation

Abandoned → [laravel/framework](/?search=laravel%2Fframework)ArchivedLibrary[Mail &amp; Notifications](/categories/mail)

idf/laravel-real-email-validation
=================================

A Laravel rule for performing email addresses validation via regex and DNS checks

1.0.1(6y ago)06.7kMITPHPPHP &gt;=7.1

Since Aug 2Pushed 6y ago4 watchersCompare

[ Source](https://github.com/InteractionDesignFoundation/laravel-real-email-validation)[ Packagist](https://packagist.org/packages/idf/laravel-real-email-validation)[ Docs](https://github.com/InteractionDesignFoundation/laravel-real-email-validation)[ RSS](/packages/idf-laravel-real-email-validation/feed)WikiDiscussions master Synced today

READMEChangelog (2)Dependencies (5)Versions (3)Used By (0)

Real email validation for Laravel
=================================

[](#real-email-validation-for-laravel)

[![Build Status](https://camo.githubusercontent.com/494e8b647d2460c547bcf7302588d5c6e3b86833737375639308cddba39bd10c/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f496e746572616374696f6e44657369676e466f756e646174696f6e2f6c61726176656c2d7265616c2d656d61696c2d76616c69646174696f6e2f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/InteractionDesignFoundation/laravel-real-email-validation)[![Code coverage](https://camo.githubusercontent.com/117f4acdb5d36c9f63386efde12f0a77127f0696b6def5baeb0c5593ee1f710d/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f496e746572616374696f6e44657369676e466f756e646174696f6e2f6c61726176656c2d7265616c2d656d61696c2d76616c69646174696f6e2f6261646765732f636f7665726167652e706e67)](https://scrutinizer-ci.com/g/InteractionDesignFoundation/laravel-real-email-validation)[![Quality Score](https://camo.githubusercontent.com/bf71e485fca0bf31534efe369a44fb2f749485840cab6d48baf102e2c43e6663/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f496e746572616374696f6e44657369676e466f756e646174696f6e2f6c61726176656c2d7265616c2d656d61696c2d76616c69646174696f6e2e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/InteractionDesignFoundation/laravel-real-email-validation)[![StyleCI](https://camo.githubusercontent.com/c07b1eddc7fd03a38b1ce2950fcad3c4b4d4d064a76045223a05d2212ee18df4/68747470733a2f2f6769746875622e7374796c6563692e696f2f7265706f732f3230303239323931362f736869656c643f6272616e63683d6d6173746572)](https://github.styleci.io/repos/200292916)[![Latest Version on Packagist](https://camo.githubusercontent.com/57dbc4173cbeda96aa584c2406bb2d1389ec2133448b3419ff0090d88217139f/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6964662f6c61726176656c2d7265616c2d656d61696c2d76616c69646174696f6e2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/idf/laravel-real-email-validation)[![Total Downloads](https://camo.githubusercontent.com/4ee441fb6c8e7f1343784e2a90d064967046f3615ce0d2557e2d3309aa290083/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6964662f6c61726176656c2d7265616c2d656d61696c2d76616c69646174696f6e2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/idf/laravel-real-email-validation)

> ⚠️ This feature is available in Laravel from v5.8.33 (see [PR](https://github.com/laravel/framework/pull/29589)) and thus this package is deprecated. By default, this package uses `['html5', 'rfc', 'host']` validation rules, you can replace it by `['email:rfc,dns']`. Unfortunately, Laravel doesn't provide `html5` validation. Read more about [Laravel email validation](https://laravel.com/docs/master/validation#rule-email).

Laravel has a good `email` validation rule, but it can miss some invalid email addresses. This packages aims to cover more cases.

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

[](#installation)

You can install the package via composer:

```
composer require idf/laravel-real-email-validation
```

The package will automatically register itself.

### Translations

[](#translations)

If you wish to edit the package translations, you can run the following command to publish them into your `resources/lang` folder

```
php artisan vendor:publish --provider="IDF\RealEmailValidation\ServiceProvider"
```

Usage
-----

[](#usage)

```
$this->validate($request, [
    'email' => ['required', 'email', new RealEmail()],
]);
```

By default it uses the following checks: `html5`, `rfc`, `host`, but you can define your set:

```
// checks without network requests
new RealEmail(['html5', 'rfc'])
```

1. `html5`: Uses regex pattern for rules defined by [WHATWG](https://html.spec.whatwg.org/multipage/input.html#valid-e-mail-address). Browsers use it for `input[type="email"]`.
2. `rfc`: Strict RFC validation. Check against RFC 5321, 5322, 6530, 6531, 6532, treats warnings as errors.
3. `host`: Checks DNS Records for the host extracted from email address. Uses network.
4. `mx`: Check DNS Records for MX type only. ⚠️ This option is not reliable because it depends on the network conditions and some valid servers refuse to respond to those requests.

### 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)

- [All Contributors](../../contributors)
- Symfony validation (for inspiration)

License
-------

[](#license)

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

###  Health Score

29

—

LowBetter than 60% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity55

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 53.3% 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 ~24 days

Total

2

Last Release

2450d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/c9acedf8ce33bd0f1b27bc0de9ea640544c778c1752263254e9591b2f2661dec?d=identicon)[alies-dev](/maintainers/alies-dev)

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

---

Top Contributors

[![alies-dev](https://avatars.githubusercontent.com/u/5278175?v=4)](https://github.com/alies-dev "alies-dev (16 commits)")[![tmbenhura](https://avatars.githubusercontent.com/u/15052407?v=4)](https://github.com/tmbenhura "tmbenhura (11 commits)")[![lptn](https://avatars.githubusercontent.com/u/150333538?v=4)](https://github.com/lptn "lptn (3 commits)")

---

Tags

email-validationlaravellaravel-validationemailemail validationlaravel-real-email-validation

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/idf-laravel-real-email-validation/health.svg)

```
[![Health](https://phpackages.com/badges/idf-laravel-real-email-validation/health.svg)](https://phpackages.com/packages/idf-laravel-real-email-validation)
```

###  Alternatives

[egulias/email-validator

A library for validating emails against several RFCs

11.6k691.3M307](/packages/egulias-email-validator)[propaganistas/laravel-disposable-email

Disposable email validator

5762.6M6](/packages/propaganistas-laravel-disposable-email)[daveearley/daves-email-validation-tool

An easy to use, accurate-ish &amp; extensible email validation library for PHP 7+

284318.9k2](/packages/daveearley-daves-email-validation-tool)[erag/laravel-disposable-email

A Laravel package to detect and block disposable email addresses.

226102.4k](/packages/erag-laravel-disposable-email)[voku/email-check

email-check (syntax, dns, trash, ...) library

504.1M4](/packages/voku-email-check)[neverbounce/neverbounce-php

This package provides convenient methods to integrate the NeverBounce API into your project.

241.1M3](/packages/neverbounce-neverbounce-php)

PHPackages © 2026

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