Mail Log Plugin
Log every email your October CMS site sends — with delivery status, open tracking and resend.
Demo URL: https://october-demo.renatio.com/backend/backend/auth/signin
Login: maillog
Password: maillog
Check whether a user received an important email, or simply confirm that mail is going out at all.
Features
- Log all outgoing emails, with a cap on the size kept
- Delivery status: sent, failed with the recorded error, or pending
- Resend a logged message to its original recipients
- Optional storage of sent attachments, with download and resend
- Skip the body of chosen templates, so a password reset link never lands in the log
- Open tracking
- Mail Activity dashboard widget
- CSV export
- Automatic pruning of old logs
- Fine-grained permissions
- Works out of the box
Requirements
This plugin requires October CMS 4.x and PHP 8.3 or newer.
If you are running October CMS 3.x or older, use the 1.x branch of this plugin.
Why is this a paid plugin?
Something that is free has little or no perceived value. Users do not commit to free products and only use them until something else looks nice and is free comes along. When I invest my time in the development of a new plugin I commit to supporting and maintaining it. I ask my customers to do the same. I do not make money from this plugin by advertisements, upgrades or additional services like hosting or setup.
Did you know that 30% of your purchase or donation goes to help fund the October Project?
My plugins take many hours to develop (40-120+) and even more hours to document and maintain. My paid plugins have to pay for both this time, and the time I am spending on free plugins and less successful paid plugins. This means that it will take even a successful plugin years to become profitable. Please consider buying an extended license if you want me to continue to maintain these plugins for the very small fee I ask in return or hire me for adding functionality that you feel is missing but valuable.
Like this plugin?
If you like this plugin, give this plugin a like or make a donation with PayPal.
My other plugins
Please check my other plugins.
Support
Please use GitHub Issues Page to report any issues with the plugin.
Reviews should not be used for getting support or reporting bugs, if you need support please use the Plugin support link.
Icon made by Darius Dan from www.flaticon.com.
This plugin is also included into the following bundle
Installation via Command Line
php artisan plugin:install Renatio.MailLog
Usage
The plugin works out of the box. It logs every mail sent from October CMS, including mail sent from other plugins and from the queue.
The log lives in Settings -> Logs -> Mail Logs. Click a record to open its preview, which shows the message details and renders the original message body.
Settings
Settings -> Logs -> Mail Log Settings.
Prune period in days
Records older than this are deleted once a day by a scheduled task. The default is 30 days; 0 or empty keeps
records forever. Logged messages hold the full mail body and the recipient IP address, so keeping them indefinitely
should be a deliberate choice.
Important note: For scheduled tasks to operate correctly you must set up the scheduler: https://docs.octobercms.com/4.x/setup/scheduler.html
Track when user opens email
Adds an invisible image to every HTML message to record when it is opened. Enabled by default.
Open tracking is a best-effort signal: many mail clients block remote images, and privacy proxies fetch them without the recipient reading the message. When tracking is off, the open columns and the Opened filter disappear from the list.
Maximum message size in MB
Caps the copy of the message body kept in the log; the message itself always goes out whole. The default is 1 MB,
0 keeps every body in full. Templates that inline images as base64 write megabytes into the log on every send,
which is what this limit is for.
A truncated message cannot be resent, and the preview says so.
Templates whose content is not stored
Messages built from the templates named here are logged with their recipients, subject and status, but without their content. Use it for mail carrying a secret, such as the password reset link. Such a message cannot be resent.
Store attachments
Keeps a copy of every attachment sent, so it can be downloaded from the preview and included in a resend. Disabled by default.
Copies are written outside the web root, under storage/app/uploads/protected, and can only be downloaded by users
with the renatio.maillog.manage_logs.attachments permission; everyone else sees the file names as plain text. Files
are stored only once the mail transport has accepted the message, and images embedded with cid: are not stored.
Stored files are removed together with their log record, whether it is deleted, emptied or pruned.
Maximum attachment size in MB
Attachments larger than this are not stored; only their name stays in the log. The default is 10 MB, 0 stores
everything. The whole attachment is read into memory to be measured, so a generous limit needs a matching PHP
memory_limit.
Delivery status
| Status | Meaning |
|---|---|
| Sent | The mail transport accepted the message. |
| Failed | Sending threw an error; the error message is recorded on the record. |
| Pending | The outcome is unknown. The message was logged, but neither a send nor a failure followed. |
Pending is not a transient state: the message is logged just before the transport runs and marked as sent right after, so a record that is still Pending after a few minutes should be treated as not sent. It stays Pending when:
- the process died between logging and sending — a fatal error, a PHP timeout, a killed queue worker;
- a
MessageSendinglistener, or amailer.prepareSendlistener registered after the plugin, returnedfalseand stopped the send; - sending threw an exception the plugin could not attribute to the send, for example one wrapped in a custom
exception without the original as
previous; - the application caught the exception without reporting it, so it never reached the exception handler where the
plugin records failures. A caught exception passed to
report()still marks the record as Failed.
The Pending filter lists such records.
Note: A queued mailable is logged again on every attempt, so a message that fails twice before finally being delivered leaves two failed rows plus one sent row.
Resend
The preview has a Resend button for users with the renatio.maillog.manage_logs.resend permission. It sends the
stored body and subject to the original To, CC and BCC recipients, with the original reply-to address and the stored
attachments where available, using the mail configuration currently in effect. The original sender is not reused.
The resent message is logged as a new record that links back to the original and names who resent it; the original lists every resend.
Filters
- Template - the mail template the message was built from
- Sent / Failed / Pending - delivery outcome
- Opened - opened at least once (hidden when open tracking is off)
- Created at - a date range
The From and Last Opened columns are hidden by default; turn them on with the list setup button.
Mail Activity dashboard widget
Add it on the dashboard with Add widget -> Mail Activity. It shows the total logged, sent, opened and failed
messages for the last days days (7 by default). The figures are cached for one minute.
Export
The Export all button in the list toolbar, available with the renatio.maillog.manage_logs.export permission,
exports the whole log to CSV, streamed in chunks so a large log does not exhaust memory. The rows checked and the
filters set on the list have no effect on it.
Permissions
| Permission | Grants |
|---|---|
renatio.maillog.manage_logs |
Access to the Mail Logs list and the dashboard widget. |
renatio.maillog.manage_logs.preview |
Opening the preview of a single logged message. |
renatio.maillog.manage_logs.delete |
Deleting selected records from the list. |
renatio.maillog.manage_logs.truncate |
Emptying the whole log with the "Empty Mail Log" button. |
renatio.maillog.manage_logs.export |
Exporting the log to CSV. |
renatio.maillog.manage_logs.resend |
Resending a logged message from its preview. |
renatio.maillog.manage_logs.attachments |
Downloading a stored attachment from the preview. |
renatio.maillog.manage_settings |
Access to the Mail Log Settings page. |
renatio.maillog.manage_logs is required to reach the list at all; the other permissions gate individual actions.
-
Trias Nur Rahman
Found the plugin not useful on 19 Mar, 2023
Doesn't work when it has attachments. Already opened the issue on Github too, but no response.
-
Renatio author
Replied on 19 Mar, 2023
It was the issue with PHP 8.0 and composer pulling older version of symfony/mime package for Laravel, it works for PHP 8.1.
It should be fixed in v1.0.5, so please upgrade the plugin.
P.S. Please in the future wait a couple of days after reporting the issue, before writing negative review.
-
Wachem Huyge
Found the plugin useful on 8 Mar, 2023
Perfect! Does exactly what it needs to do. Keep it up!
-
| 3.1.0 |
Log the reply-to address and reuse it on resend. Explain the Pending status in the preview and add a Pending filter. Aug 28, 2026 |
|---|---|
| 3.0.0 |
Rename the permission codes to the convention the other Renatio plugins use and require PHP 8.3. Aug 25, 2026 |
| 2.4.0 |
Record who resent a message, skip the body for chosen templates and stop listing embedded images as attachments. Aug 25, 2026 |
| 2.3.0 |
Cap the size of the mail body kept in the log. Aug 25, 2026 |
| 2.2.0 |
Optionally store sent attachments, download them from the log and resend them. Aug 25, 2026 |
| 2.1.0 |
Track failed deliveries, resend messages and report on mail activity. Aug 25, 2026 |
| 2.0.6 |
Fix 404 on the mail preview under October 4.3.5 by renaming the action to snake_case. Aug 22, 2026 |
| 2.0.5 |
Refactor to use pluck() function. Oct 07, 2025 |
| 2.0.4 |
Update dependencies. Jul 12, 2025 |
| 2.0.3 |
Fix issue with logging email. Jul 12, 2025 |
| 2.0.2 |
Minor fix. Jul 07, 2025 |
| 2.0.1 |
Require October 4. Jun 30, 2025 |
| 1.0.6 |
Minor fix. Sep 25, 2023 |
| 1.0.5 |
Fix logging attachments for php@8.0. Mar 19, 2023 |
| 1.0.4 |
Only log template name for registered mail templates. Feb 16, 2023 |
| 1.0.3 |
Add template filter. Improve permissions. Nov 22, 2022 |
| 1.0.2 |
Docs. Nov 20, 2022 |
| 1.0.1 |
Initialize plugin. Nov 20, 2022 |
Upgrading To 2.0.0
The plugin requires October CMS 4.x. If you are still running October CMS 3, stay on the 1.x branch.
Upgrading To 2.0.6
The controller action previewEmail was renamed to preview_email. Update any code that extends the MailLogs
controller or links to that action directly.
Upgrading To 2.1.0
- Run
php artisan october:migrate. - Grant the new
utilities.mail_logs.resendpermission to the roles that should be able to resend mail. - If you serve a mirrored public folder, run
php artisan october:mirror, or the Mail Activity widget renders unstyled.
Upgrading To 2.2.0
Attachment storage is off by default. To use it, enable Store attachments in the settings and grant the new
utilities.mail_logs.attachments permission to the roles that should be able to download stored files.
Upgrading To 2.3.0
Run php artisan october:migrate.
Message bodies are now capped at 1 MB in the log. Set Maximum message size in MB to 0 to keep every body in
full, as before.
Upgrading To 2.4.0
Run php artisan october:migrate.
Upgrading To 3.0.0
The plugin requires PHP 8.3 or newer; upgrade the runtime before running Composer.
The permission codes changed, so run php artisan october:migrate. The migration rewrites existing grants, so nobody
loses access. The permissions also moved from the Utilities tab into their own Mail Logs tab.
| Before | After |
|---|---|
utilities.mail_logs |
renatio.maillog.manage_logs |
utilities.mail_logs.preview |
renatio.maillog.manage_logs.preview |
utilities.mail_logs.delete |
renatio.maillog.manage_logs.delete |
utilities.mail_logs.truncate |
renatio.maillog.manage_logs.truncate |
utilities.mail_logs.export |
renatio.maillog.manage_logs.export |
utilities.mail_logs.resend |
renatio.maillog.manage_logs.resend |
utilities.mail_logs.attachments |
renatio.maillog.manage_logs.attachments |
utilities.mail_logs_settings |
renatio.maillog.manage_settings |
If your own code calls hasAccess() or userHasAccess() with one of the old codes, update those calls.
Upgrading To 3.1.0
Run php artisan october:migrate.
A resend is now logged as a record linked to its original, carrying who resent it, and the original lists every
resend. The resent_at column is dropped and the resent_by values held on originals are cleared, since earlier
resends cannot be matched to their originals.




