PHPackages                             crasivo/bitrix-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. crasivo/bitrix-monolog

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

crasivo/bitrix-monolog
======================

Monolog library adapter for 1C-Bitrix

1.0.0(9mo ago)0501[1 PRs](https://github.com/crasivo/bitrix-monolog/pulls)MITPHPPHP ^8.1

Since Sep 10Pushed 6mo agoCompare

[ Source](https://github.com/crasivo/bitrix-monolog)[ Packagist](https://packagist.org/packages/crasivo/bitrix-monolog)[ Docs](https://github.com/crasivo/bitrix-monolog)[ GitHub Sponsors](https://github.com/crasivo)[ RSS](/packages/crasivo-bitrix-monolog/feed)WikiDiscussions main Synced 3w ago

READMEChangelog (6)Dependencies (1)Versions (7)Used By (0)

✍🏻 Bitrix Monolog
=================

[](#-bitrix-monolog)

Adapter for the popular [Monolog](https://github.com/Seldaek/monolog) library in 1C-Bitrix &amp; Bitrix24.

Implementation features:

- Simple and quick integration into an existing project
- Flexible configuration (like laravel/symfony)
- Isolation of kernel settings and specific module settings
- Backward compatibility with [standard loggers](https://dev.1c-bitrix.ru/learning/course/index.php?COURSE_ID=43&LESSON_ID=15330)
- Handling critical errors through the [exception\_handling](https://dev.1c-bitrix.ru/learning/course/index.php?COURSE_ID=43&LESSON_ID=2795) configuration.
- Quick integration with external services *(Graylog, Logstash, Sentry etc)*.

Minimum requirements for installation:

- 1C-Bitrix kernel version (main): `v20.5.400`
- PHP version: `v7.2`
- Monolog version: `v2.10`

🚀 Quick Start
=============

[](#-quick-start)

To use the library, simply install the [Composer](https://getcomposer.org/) package via the command:

```
$ cd /path/to/project
$ composer require crasivo/bitrix-monolog
```

It is initially assumed that `autoload.php` is already connected to your project. If this is not the case, it can be added to one of the following files:

- `/bitrix/.settings.php`
- `/bitrix/.settings_extra.php`
- `/local/php_interface/init.php`

The service is already pre-configured (default logger). This is quite enough to start logging messages anywhere in your project. Access to the logger and other objects is through a separate `ServiceLocator` class (service locator).

Example of accessing the logger through the service locator:

```
use Crasivo\Bitrix\Monolog\ServiceLocator as MonologLocator;

$locator = MonologLocator::getInstance();
$logger = $locator->getLogger('default');
$logger->info('Hello world!');
```

You can also use the ready-made helper function (alternative):

```
logger()->info('Hello world!');
```

Warning

Direct call of any method in files such as `.settings.php` can lead to looping (stack overflow). Keep this in mind during development!

To configure logging of [critical errors](https://dev.1c-bitrix.ru/learning/course/index.php?COURSE_ID=43&LESSON_ID=2795), it is sufficient to declare the corresponding class.

```
return [
    'exception_handling' => [
        'value' => [
            'debug' => false,
            'handled_errors_types' => E_ALL & ~E_NOTICE & ~E_STRICT & ~E_USER_NOTICE,
            'exception_errors_types' => E_ALL & ~E_NOTICE & ~E_WARNING & ~E_STRICT & ~E_USER_WARNING & ~E_USER_NOTICE & ~E_COMPILE_WARNING & ~E_DEPRECATED,
            'ignore_silence' => false,
            'assertion_throws_exception' => true,
            'assertion_error_type' => E_USER_ERROR,
            'log' => [
                'class_name' => Crasivo\Bitrix\Monolog\ExceptionHandlerLog::class,
                'settings' => [
                    'logger' => 'default',
                ],
            ],
        ],
        'readonly' => true,
    ],
];
```

In the `examples` folder, you can see examples with settings and using the library.

Note

More detailed documentation with usage examples will be written and published later. Estimated release date — Q4 2025.

---

📜 License
---------

[](#-license)

This project is distributed under the [MIT](https://en.wikipedia.org/wiki/MIT_License) license. The full text of the license can be read in the [LICENSE](LICENSE) file.

###  Health Score

35

—

LowBetter than 77% of packages

Maintenance62

Regular maintenance activity

Popularity11

Limited adoption so far

Community7

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

Total

5

Last Release

288d ago

Major Versions

0.0.4 → 1.0.02025-09-12

PHP version history (2 changes)0.0.1PHP ^7.2 || ^8.0

1.0.0PHP ^8.1

### Community

Maintainers

![](https://www.gravatar.com/avatar/a2f02d0201cef681d3e7959c0df669654e11b485ac81b49a44d771dda48484bf?d=identicon)[crasivo](/maintainers/crasivo)

---

Top Contributors

[![crasivo](https://avatars.githubusercontent.com/u/130065622?v=4)](https://github.com/crasivo "crasivo (10 commits)")

---

Tags

bitrixbitrix24loggingbitrixadaptermonolog

### Embed Badge

![Health badge](/badges/crasivo-bitrix-monolog/health.svg)

```
[![Health](https://phpackages.com/badges/crasivo-bitrix-monolog/health.svg)](https://phpackages.com/packages/crasivo-bitrix-monolog)
```

###  Alternatives

[inpsyde/wonolog

Monolog-based logging package for WordPress.

184631.3k7](/packages/inpsyde-wonolog)[honeybadger-io/honeybadger-laravel

Honeybadger Laravel integration

431.3M](/packages/honeybadger-io-honeybadger-laravel)[logtail/monolog-logtail

Logtail handler for Monolog

233.5M3](/packages/logtail-monolog-logtail)[naoray/laravel-github-monolog

Log driver to store logs as github issues

10822.5k](/packages/naoray-laravel-github-monolog)[kdyby/monolog

Integration of Monolog into Nette Framework

32700.0k10](/packages/kdyby-monolog)[inpsyde/logzio-monolog

Logz.io integration for Monolog

181.2M1](/packages/inpsyde-logzio-monolog)

PHPackages © 2026

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