PHPackages                             yarcode/yii2-email-manager - 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. yarcode/yii2-email-manager

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

yarcode/yii2-email-manager
==========================

Yii2 Email Manager

0.2.0(10y ago)41.7k4[1 issues](https://github.com/yarcode/yii2-email-manager/issues)[1 PRs](https://github.com/yarcode/yii2-email-manager/pulls)MITPHPPHP &gt;=5.4.0

Since Jan 19Pushed 9y ago3 watchersCompare

[ Source](https://github.com/yarcode/yii2-email-manager)[ Packagist](https://packagist.org/packages/yarcode/yii2-email-manager)[ RSS](/packages/yarcode-yii2-email-manager/feed)WikiDiscussions master Synced 4w ago

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

Email Module
============

[](#email-module)

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

[](#installation)

Simple configuration:

```
'components' => [
    'emailManager' => [
        'class' => '\yarcode\email\EmailManager',
        'transports' => [
            'yiiMailer' => '\yarcode\email\transports\YiiMailer'
        ],
    ],
]

```

Multi transport configuration:

```
'components' => [
    'emailManager' => [
        'class' => '\yarcode\email\EmailManager',
        'defaultTransport' => 'yiiMailer',
        'transports' => [
            'yiiMailer' => [
                'class' => '\yarcode\email\transports\YiiMailer',
            ],
            'mailGun' => [
                'class' => '\yarcode\email\transports\MailGun',
                'apiKey' => 'xxx',
                'domain' => 'our-domain.net',
            ],
        ],
    ],
]

```

Add command to the list of the available commands. Put it into console app configuration:

```
'controllerMap' => [
    'email' => '\yarcode\email\commands\EmailCommand',
],

```

Add email sending daemon into crontab via lockrun or run-one utils:

```
*/5 * * * * run-one php /your/site/path/yii email/run-spool-daemon

```

OR, if you will use cboden/ratchet

```
*/5 * * * * run-one php /your/site/path/yii email/run-loop-daemon

```

Usage
-----

[](#usage)

```
// obtain component instance
$emailManager = EmailManager::geInstance();
// direct send via default transport
$emailManager->send('from@example.com', 'to@example.com', 'test subject', 'test email');
// queue send via default transport
$emailManager->send('from@example.com', 'to@example.com', 'test subject', 'test email');
// direct send via selected transport
$emailManager->transports['mailGun']->send('from@example.com', 'to@example.com', 'test subject', 'test email');

// use shortcuts
EmailTemplate::findByShortcut('shortcut_name')->queue('recipient@email.org', ['param1' => 1, 'param2' => 'asd']);

```

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance15

Infrequent updates — may be unmaintained

Popularity22

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity49

Maturing project, gaining track record

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

Total

2

Last Release

3730d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1297270?v=4)[Vahid G](/maintainers/lagman)[@lagman](https://github.com/lagman)

---

Top Contributors

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

---

Tags

emailyii2modulecomponentemail queueemail manager

### Embed Badge

![Health badge](/badges/yarcode-yii2-email-manager/health.svg)

```
[![Health](https://phpackages.com/badges/yarcode-yii2-email-manager/health.svg)](https://phpackages.com/packages/yarcode-yii2-email-manager)
```

###  Alternatives

[nterms/yii2-mailqueue

Email queue component for yii2 that works with yii2-swiftmailer.

84133.5k2](/packages/nterms-yii2-mailqueue)[yiimaker/yii2-email-templates

Extension for creating of email templates and manage using your site dashboard

9219.8k1](/packages/yiimaker-yii2-email-templates)[loveorigami/yii2-notification-wrapper

This module for renders a message from session flash (with ajax, pjax support and etc.)

76204.2k5](/packages/loveorigami-yii2-notification-wrapper)[boundstate/yii2-mailgun

Mailgun integration for the Yii framework

28165.8k](/packages/boundstate-yii2-mailgun)[yarcode/yii2-mailgun-mailer

Mailgun mailer implementation for Yii2

1576.5k](/packages/yarcode-yii2-mailgun-mailer)

PHPackages © 2026

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