PHPackages                             sam-it/react-smtp - 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. [HTTP &amp; Networking](/categories/http)
4. /
5. sam-it/react-smtp

ActiveLibrary[HTTP &amp; Networking](/categories/http)

sam-it/react-smtp
=================

SMTP Server based on ReactPHP

v0.0.2(9y ago)132295[3 issues](https://github.com/SAM-IT/react-smtp/issues)MITPHP

Since Jan 5Pushed 9y ago2 watchersCompare

[ Source](https://github.com/SAM-IT/react-smtp)[ Packagist](https://packagist.org/packages/sam-it/react-smtp)[ RSS](/packages/sam-it-react-smtp/feed)WikiDiscussions master Synced 3w ago

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

react-smtp
==========

[](#react-smtp)

SMTP Server based on ReactPHP

It supports many concurrent STMP connections.

[![Scrutinizer Code Quality](https://camo.githubusercontent.com/ccd05136a5c1b09fb12b73afa40488b62a95a152df5449e06e6b14b056536f2b/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f53414d2d49542f72656163742d736d74702f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/SAM-IT/react-smtp/?branch=master)[![Code Coverage](https://camo.githubusercontent.com/7b5983b2d50a1d0f0c60d6f2d25be32d0a956211014bbf18203306658bbef2c5/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f53414d2d49542f72656163742d736d74702f6261646765732f636f7665726167652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/SAM-IT/react-smtp/?branch=master)[![Build Status](https://camo.githubusercontent.com/08e295f9d03b212d2b1f8342b42fda2abf35932edef3e4bd982749ecdfd8aff8/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f53414d2d49542f72656163742d736d74702f6261646765732f6275696c642e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/SAM-IT/react-smtp/build-status/master)

Usage example
=============

[](#usage-example)

Server:
-------

[](#server)

```
include 'vendor/autoload.php';

$loop = React\EventLoop\Factory::create();
$server = new \SamIT\React\Smtp\Server($loop);
$server->listen(8025);
$server->on('message', function($from, array $recipients, \SamIT\React\Smtp\Message $message, \SamIT\React\Smtp\Connection $connection) {
    var_dump($message->getHeaders());
    var_dump($message->getBody()->getSize());
});
$loop->run();

```

### Example client using PHPMailer:

[](#example-client-using-phpmailer)

```

include 'vendor/autoload.php';

$mail = new PHPMailer();

$mail->isSMTP();
$mail->Host = 'localhost';
$mail->Port = 8025;
$mail->SMTPDebug = true;

$mail->setFrom('from@example.com', 'Mailer');
$mail->addAddress('joe@example.net', 'Joe User');     // Add a recipient
$mail->addAddress('ellen@example.com');               // Name is optional
$mail->addReplyTo('info@example.com', 'Information');
$mail->addCC('cc@example.com');
$mail->addBCC('bcc@example.com');

$mail->Subject = 'Here is the subject';
$mail->Body    = 'This is the HTML message body in bold!';
$mail->AltBody = 'This is the body in plain text for non-HTML mail clients';

if(!$mail->send()) {
    echo 'Message could not be sent.';
    echo 'Mailer Error: ' . $mail->ErrorInfo;
} else {
    echo 'Message has been sent';
}

```

###  Health Score

28

—

LowBetter than 52% of packages

Maintenance15

Infrequent updates — may be unmaintained

Popularity20

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 96% 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 ~11 days

Total

2

Last Release

3445d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/18b13c534e3812b66a72645fe215301b54fc4d288f6396fee9385b681e27da18?d=identicon)[SamMousa](/maintainers/SamMousa)

---

Top Contributors

[![SamMousa](https://avatars.githubusercontent.com/u/547021?v=4)](https://github.com/SamMousa "SamMousa (24 commits)")[![smalot](https://avatars.githubusercontent.com/u/1424035?v=4)](https://github.com/smalot "smalot (1 commits)")

### Embed Badge

![Health badge](/badges/sam-it-react-smtp/health.svg)

```
[![Health](https://phpackages.com/badges/sam-it-react-smtp/health.svg)](https://phpackages.com/packages/sam-it-react-smtp)
```

###  Alternatives

[aws/aws-sdk-php

AWS SDK for PHP - Use Amazon Web Services in your PHP project

6.2k532.1M2.5k](/packages/aws-aws-sdk-php)[guzzlehttp/psr7

PSR-7 message implementation that also provides common utility methods

7.9k1.1B3.7k](/packages/guzzlehttp-psr7)[algolia/algoliasearch-client-php

API powering the features of Algolia.

69634.4M144](/packages/algolia-algoliasearch-client-php)[gotenberg/gotenberg-php

A PHP client for interacting with Gotenberg, a developer-friendly API for converting numerous document formats into PDF files, and more!

3845.9M26](/packages/gotenberg-gotenberg-php)[neuron-core/neuron-ai

The PHP Agentic Framework.

2.0k496.1k33](/packages/neuron-core-neuron-ai)[shopify/shopify-api

Shopify API Library for PHP

4655.2M19](/packages/shopify-shopify-api)

PHPackages © 2026

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