PHPackages                             jfoucher/mailocal - 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. [Debugging &amp; Profiling](/categories/debugging)
4. /
5. jfoucher/mailocal

AbandonedArchivedProject[Debugging &amp; Profiling](/categories/debugging)

jfoucher/mailocal
=================

Debug your emails while making sure real customers never see them.

v0.5.5(6y ago)781.2k15[14 PRs](https://github.com/jfoucher/Mailocal/pulls)MITPHPPHP ^7.3

Since Feb 21Pushed 3y ago2 watchersCompare

[ Source](https://github.com/jfoucher/Mailocal)[ Packagist](https://packagist.org/packages/jfoucher/mailocal)[ RSS](/packages/jfoucher-mailocal/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (6)Dependencies (30)Versions (28)Used By (0)

[![License: MIT](https://camo.githubusercontent.com/fdf2982b9f5d7489dcf44570e714e3a15fce6253e0cc6b5aa61a075aac2ff71b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d79656c6c6f772e737667)](https://opensource.org/licenses/MIT)[![Build status](https://camo.githubusercontent.com/384c2cdd050d2920644fd382b06352b787ffac8e78e4c1f5553b96c86bd90043/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f6a666f75636865722f4d61696c6f63616c2e737667)](https://camo.githubusercontent.com/384c2cdd050d2920644fd382b06352b787ffac8e78e4c1f5553b96c86bd90043/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f6a666f75636865722f4d61696c6f63616c2e737667)

[![](favicon.png)](favicon.png)

Mailocal
========

[](#mailocal)

Safely test sending your emails by using this local SMTP server and viewing the results on the web interface.

By using this locally installed SMTP server you can be sure that your real customers will never see your test emails!

However you can see all of them by simply opening the provided interface in any browser.

Screenshots
-----------

[](#screenshots)

[![All messages](https://camo.githubusercontent.com/6de077e2ea325c8fc151122102c67c096d30b9e32cf26fbee64cbd868ecd18c7/68747470733a2f2f6d61696c6f63616c2e6a666f75636865722e636f6d2f6173736574732f696d672f696d67312e706e67 "List of messages, can be filtered by recipient")](https://camo.githubusercontent.com/6de077e2ea325c8fc151122102c67c096d30b9e32cf26fbee64cbd868ecd18c7/68747470733a2f2f6d61696c6f63616c2e6a666f75636865722e636f6d2f6173736574732f696d672f696d67312e706e67)[![single message](https://camo.githubusercontent.com/9e18288b96c65dc471ac347cf878286db1da3a823bb3a20aaec0afd8bfefd40f/68747470733a2f2f6d61696c6f63616c2e6a666f75636865722e636f6d2f6173736574732f696d672f696d67322e706e67 "Viewing a single message")](https://camo.githubusercontent.com/9e18288b96c65dc471ac347cf878286db1da3a823bb3a20aaec0afd8bfefd40f/68747470733a2f2f6d61696c6f63616c2e6a666f75636865722e636f6d2f6173736574732f696d672f696d67322e706e67)

Requirements
------------

[](#requirements)

- [php 7.3](https://php.net)
- ext-curl (php7.2-curl)
- ext-mbstring (php7.2-mbstring)
- ext-sqlite3 (php7.2-sqlite3)
- ext-xml (php7.2-xml)
- ext-zip (php7.2-zip)
- [composer](https://getcomposer.org)

If you don't have Composer yet, download it following the instructions on  or just run the following command:

```
curl -s http://getcomposer.org/installer | php

```

Install
-------

[](#install)

- `composer create-project jfoucher/mailocal`
- That's it

Running
-------

[](#running)

[![](console.png)](console.png)

- `cd mailocal` to enter the directory just created by composer
- Run `bin/mailocal` to run both the SMTP server and the web server

Alternatively you can:

- Run `yarn run build` to build the frontend assets
- `php bin/console email:server` to launch the SMTP server
- `php bin/console server:start` to start Symfony's built-in web server

Configuration
-------------

[](#configuration)

- Configure your other apps to use this new local SMTP server:
    - host: `127.0.0.1`
    - port: `2525` (or the one you chose, see below)
    - You can configure a SMTP username and password by setting the `SMTP_SERVER_USER` and `SMTP_SERVER_PASSWORD` fields in your `.env` file. Make sure you update your email client's credentials accordingly.
- [Mailocal](/) uses an SQLite database by default (in `var/data.db`) but you can choose to use any other database by setting the correct URL in the `.env` file.
- By default, `bin/mailocal` will start a web server that listens on 127.0.0.1 (address) and the first free port starting from 8000. This is where you can view any emails you receive. You can force `bin/mailocal` to always listen on a specific address/port by setting the value of `WEB_SERVER_ADDRESSPORT` in your `.env` file. The value can be address:port, address, or port.

Done
----

[](#done)

You can now view any emails you receive by opening  in your browser

The SMTP runs on port 2525 by default. Pass the `--port` option to use another one, like this: `php bin/console email:server --port=587`

License
-------

[](#license)

This project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details

Warning
-------

[](#warning)

Never use this in production, only run it on your local machine.

###  Health Score

33

—

LowBetter than 75% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity30

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity55

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 92.5% 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 ~44 days

Recently: every ~109 days

Total

11

Last Release

2190d ago

PHP version history (3 changes)v0.1PHP ^7.1.3

v0.3PHP ^7.2

v0.5.5PHP ^7.3

### Community

Maintainers

![](https://www.gravatar.com/avatar/1a214dd3e770b8f6e835a86d87e0da2321ef2cdddc15fdcd4fb98327562587a3?d=identicon)[jfoucher](/maintainers/jfoucher)

---

Top Contributors

[![jfoucher](https://avatars.githubusercontent.com/u/152015?v=4)](https://github.com/jfoucher "jfoucher (99 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (7 commits)")[![richardsjoqvist](https://avatars.githubusercontent.com/u/905706?v=4)](https://github.com/richardsjoqvist "richardsjoqvist (1 commits)")

###  Code Quality

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/jfoucher-mailocal/health.svg)

```
[![Health](https://phpackages.com/badges/jfoucher-mailocal/health.svg)](https://phpackages.com/packages/jfoucher-mailocal)
```

###  Alternatives

[prestashop/prestashop

PrestaShop is an Open Source e-commerce platform, committed to providing the best shopping cart experience for both merchants and customers.

9.0k15.4k](/packages/prestashop-prestashop)[ibexa/oss

A meta package for installing Ibexa Open Source

19772.4k11](/packages/ibexa-oss)[ec-cube/ec-cube

EC-CUBE EC open platform.

78527.0k1](/packages/ec-cube-ec-cube)[kimai/kimai

Kimai - Time Tracking

4.6k7.4k1](/packages/kimai-kimai)[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.4k5.6M651](/packages/sylius-sylius)[chameleon-system/chameleon-base

The Chameleon System core.

1026.5k3](/packages/chameleon-system-chameleon-base)

PHPackages © 2026

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