PHPackages                             syntech/notifier - 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. syntech/notifier

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

syntech/notifier
================

A Laravel package to send email notifications on errors

1.0.4(2y ago)63951MITPHPPHP &gt;=7.4

Since Jun 13Pushed 2y ago1 watchersCompare

[ Source](https://github.com/mokhdesigns/laravel-error-notifier)[ Packagist](https://packagist.org/packages/syntech/notifier)[ RSS](/packages/syntech-notifier/feed)WikiDiscussions main Synced 2w ago

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

Laravel Error Notifier
======================

[](#laravel-error-notifier)

Laravel Error Notifier is a Laravel package that sends email notifications whenever an error occurs in your Laravel application. It helps you monitor and address issues promptly.

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

[](#installation)

Step 1: Install via Composer
----------------------------

[](#step-1-install-via-composer)

You can install the package via Composer. Run the following command in your Laravel application's root directory:

```
composer require syntech/notifier
```

Step 2: Publish the Configuration File
--------------------------------------

[](#step-2-publish-the-configuration-file)

```
Publish the package's configuration file to customize the email recipient for error notifications:
```

```
php artisan vendor:publish --provider="Syntech\Notifier\LaravelErrorNotifierServiceProvider"
```

This command will create a configuration file at config/error-notifier.php.

Step 3: Configure the Email Recipient
-------------------------------------

[](#step-3-configure-the-email-recipient)

Open the newly created configuration file config/error-notifier.php and set the email address where error notifications should be sent:

```
return [
  'email' => env('ERROR_NOTIFIER_EMAIL', 'admin@example.com'),
];
```

Ensure you set the ERROR\_NOTIFIER\_EMAIL environment variable in your .env file:

ERROR\_NOTIFIER\_EMAIL=

Step 4: Configure Mail Settings
-------------------------------

[](#step-4-configure-mail-settings)

Ensure your Laravel application's mail settings are correctly configured in the .env file. Here's an example configuration using SMTP:

```
MAIL_MAILER=smtp
MAIL_HOST=smtp.mailtrap.io
MAIL_PORT=2525
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
MAIL_FROM_ADDRESS=hello@example.com
MAIL_FROM_NAME="${APP_NAME}"
```

Replace these settings with your actual mail server details.

Step 5: Update Logging Configuration
------------------------------------

[](#step-5-update-logging-configuration)

Add the custom log channel to your application's config/logging.php file:

```
use SyntechNotifier\LaravelErrorNotifier\Logging\CustomHandler;

return [
  'channels' => [
      // other channels...

      'email' => [
          'driver' => 'custom',
          'via' => CustomHandler::class,
          'level' => 'error',
      ],
  ],
];
```

Step 6: Update Exception Handler
--------------------------------

[](#step-6-update-exception-handler)

Open the app/Exceptions/Handler.php file and update the report method to log errors to the email channel:

```
use Illuminate\Support\Facades\Log;
use Throwable;

public function report(Throwable $exception)
{
  parent::report($exception);

  if ($this->shouldReport($exception)) {
      Log::channel('email')->error('An error occurred', ['exception' => $exception]);
  }
}
```

### Usage

[](#usage)

Once installed and configured, the package will automatically send an email notification whenever an error occurs in your Laravel application. Customizing the Notification Email

If you need to customize the email notification, you can modify the ErrorOccurred notification class located at src/Notifications/ErrorOccurred.php. This class defines the content and structure of the email sent when an error occurs. Example

Here is an example of what the email notification might look like:

Subject: Error Occurred in Your Application

An error has occurred:

- Message: Example error message
- File: /path/to/file.php
- Line: 123
- Stack Trace: #0 /path/to/file.php(123): exampleFunction() #1 {main}

Please address this issue promptly.

Contributing

If you would like to contribute to this package, please follow these steps:

```
Fork the repository on GitHub.
Create a new branch for your feature or bugfix.
Make your changes and commit them with a descriptive message.
Push your changes to your forked repository.
Submit a pull request to the main repository.

```

License

This package is open-source software licensed under the MIT license. Support

If you encounter any issues or have questions, please feel free to open an issue on the GitHub repository.

###  Health Score

26

—

LowBetter than 40% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity22

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity44

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 90.9% 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 ~3 days

Total

4

Last Release

783d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8aa092c27a5563bfb4a0fcb4d602f0857db0fc1947f2a6ce70e40a2ab055426b?d=identicon)[Mokhtar ali](/maintainers/Mokhtar%20ali)

---

Top Contributors

[![devmokhtar14](https://avatars.githubusercontent.com/u/261612676?v=4)](https://github.com/devmokhtar14 "devmokhtar14 (10 commits)")[![mokhdesigns](https://avatars.githubusercontent.com/u/41319367?v=4)](https://github.com/mokhdesigns "mokhdesigns (1 commits)")

### Embed Badge

![Health badge](/badges/syntech-notifier/health.svg)

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

###  Alternatives

[propaganistas/laravel-disposable-email

Disposable email validator

6023.2M7](/packages/propaganistas-laravel-disposable-email)[illuminate/mail

The Illuminate Mail package.

5910.7M572](/packages/illuminate-mail)[illuminate/notifications

The Illuminate Notifications package.

483.1M1.2k](/packages/illuminate-notifications)

PHPackages © 2026

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