PHPackages                             mm-plazz/mezzio-monolog - 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. [Logging &amp; Monitoring](/categories/logging)
4. /
5. mm-plazz/mezzio-monolog

ActiveLibrary[Logging &amp; Monitoring](/categories/logging)

mm-plazz/mezzio-monolog
=======================

Mezzio Monolog ErrorHandler

v1.0.1(11mo ago)089[3 PRs](https://github.com/mm-plazz/mezzio-monolog/pulls)GPL-3.0-or-laterPHPPHP &gt;=8.2CI passing

Since Aug 5Pushed 3w agoCompare

[ Source](https://github.com/mm-plazz/mezzio-monolog)[ Packagist](https://packagist.org/packages/mm-plazz/mezzio-monolog)[ RSS](/packages/mm-plazz-mezzio-monolog/feed)WikiDiscussions master Synced today

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

Mezzio Monolog ErrorHandler
===========================

[](#mezzio-monolog-errorhandler)

[![Latest Stable Version](https://camo.githubusercontent.com/6b42f4a566d8b06ee2eaf0b5783c21924c8317c4ec28c2a4ce5f8addabd8f5ec/68747470733a2f2f706f7365722e707567782e6f72672f6d6d2d706c617a7a2f6d657a7a696f2d6d6f6e6f6c6f672f762f737461626c65)](https://packagist.org/packages/mm-plazz/mezzio-monolog)[![Total Downloads](https://camo.githubusercontent.com/f56b2e9aac6cf74b04bd9214944e44da99ed575002aea7c1a3744e70346b881f/68747470733a2f2f706f7365722e707567782e6f72672f506c617a7a2f6d657a7a696f2d6d6f6e6f6c6f672f646f776e6c6f616473)](https://packagist.org/packages/mm-plazz/mezzio-monolog)[![Monthly Downloads](https://camo.githubusercontent.com/0d100de13304797a1ec47c10bd088625f611d39df8fa8f443d6572e43c64f6cb/68747470733a2f2f706f7365722e707567782e6f72672f506c617a7a2f6d657a7a696f2d6d6f6e6f6c6f672f642f6d6f6e74686c792e706e67)](https://packagist.org/packages/mm-plazz/mezzio-monolog)[![Software License](https://camo.githubusercontent.com/1d0502ff5784987cf1c11b96e4aea6635732d0bc4d904c83fc1af479d32b13c9/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d47504c2d2d332e302d627269676874677265656e2e737667)](LICENSE)[![Build Status](https://github.com/mm-plazz/mezzio-monolog/actions/workflows/php.yml/badge.svg)](https://github.com/mm-plazz/mezzio-monolog/actions/workflows/php.yml)

This library enables [Monolog](https://github.com/Seldaek/monolog) as an ErrorHandler in [Mezzio](https://getmezzio.org/).

It catches all uncaught exceptions and logs them to the configured Monolog handlers.

What is Mezzio?
---------------

[](#what-is-mezzio)

Mezzio is a PHP framework for building web applications and APIs. It is based on a middleware pipeline architecture, which makes it flexible and extensible.

What is Monolog?
----------------

[](#what-is-monolog)

Monolog is a popular logging library for PHP. It supports a wide variety of handlers, which allows you to send your logs to files, sockets, inboxes, databases and various web services.

Install
-------

[](#install)

Install the library using composer:

```
composer require mm-plazz/mezzio-monolog
```

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

[](#configuration)

First, you need to enable the component by adding the `Plazz\Mezzio\Monolog\ConfigProvider` to your `config/config.php`:

```
