PHPackages                             datenkraft/monolog-formatter - 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. datenkraft/monolog-formatter

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

datenkraft/monolog-formatter
============================

Datenkraft Monolog JSON Formatter

v2.0.1(2y ago)04.5k↓50%MITPHPPHP ^8.2

Since Aug 8Pushed 2y ago1 watchersCompare

[ Source](https://github.com/datenkraft/monolog-formatter)[ Packagist](https://packagist.org/packages/datenkraft/monolog-formatter)[ Docs](https://github.com/datenkraft/monolog-formatter)[ RSS](/packages/datenkraft-monolog-formatter/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (3)Versions (6)Used By (0)

README
======

[](#readme)

This library can re-format json log. The single line formatter is based on the [Datenkraft\\MonologGkeFormatter\\GkeFormatter](https://github.com/datenkraft/monolog-gke-formatter)and is optimized for the Google Kubernetes Engine, whereas the multi line formatter is for local logging with beautified output.

Both introduced formatter convert objects which would not be convertible by monolog to arrays. Please be aware that through this feature private data could be exposed to log if not adding it to the blacklist.

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

[](#installation)

```
composer require Datenkraft/monolog-formatter

```

Usage
-----

[](#usage)

```
use Monolog\Logger;
use Monolog\Handler\StreamHandler;
use Datenkraft\MonologFormatter;

$handler = new StreamHandler('php://stdout');
$handler->setFormatter(new SingleLineFormatter());
// or
$handler->setFormatter(new MultiLineFormatter());
```

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity20

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 76.2% 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 ~76 days

Total

5

Last Release

1072d ago

Major Versions

v1.2.1 → v2.0.12023-06-12

PHP version history (2 changes)v1.0.0PHP ^8.0

v2.0.1PHP ^8.2

### Community

Maintainers

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

---

Top Contributors

[![rlehner-dk](https://avatars.githubusercontent.com/u/103114558?v=4)](https://github.com/rlehner-dk "rlehner-dk (16 commits)")[![herkales](https://avatars.githubusercontent.com/u/110830400?v=4)](https://github.com/herkales "herkales (5 commits)")

---

Tags

logloggingerror-reportinggoogletracingFormattor Error

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/datenkraft-monolog-formatter/health.svg)

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

###  Alternatives

[sentry/sentry

PHP SDK for Sentry (http://sentry.io)

1.9k227.1M273](/packages/sentry-sentry)[sentry/sentry-laravel

Laravel SDK for Sentry (https://sentry.io)

1.3k114.3M154](/packages/sentry-sentry-laravel)[justbetter/magento2-sentry

Magento 2 Logger for Sentry

1851.5M3](/packages/justbetter-magento2-sentry)[gluedev/laravel-stackdriver

Enables logging, tracing and error reporting to Google Stackdriver for the Laravel framework

4865.6k](/packages/gluedev-laravel-stackdriver)[inpsyde/logzio-monolog

Logz.io integration for Monolog

191.2M1](/packages/inpsyde-logzio-monolog)[hamidrezaniazi/pecs

PHP ECS (Elastic Common Schema): Simplify logging with the power of elastic common schema.

3325.5k1](/packages/hamidrezaniazi-pecs)

PHPackages © 2026

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