PHPackages                             programster/log - 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. programster/log

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

programster/log
===============

A library of loggers that comply with PSR-3

2.1.0(2mo ago)0967↓25%3MITPHPPHP &gt;=8.2.0

Since Mar 14Pushed 2mo ago1 watchersCompare

[ Source](https://github.com/programster/package-logging)[ Packagist](https://packagist.org/packages/programster/log)[ Docs](https://github.com/programster/package-logging)[ RSS](/packages/programster-log/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (2)Versions (12)Used By (3)

Logger PHP Package
==================

[](#logger-php-package)

This is a [PSR-3](https://www.php-fig.org/psr/psr-3/) compatible logger package that provides some abstract loggers that allow:

- Minimum level logging (MinLevelLogger)
- Logging to multiple loggers (MultiLogger)
- Prefix logging - add a prefix to all messages before logging to the underlying logger.
- File logger - log to a file.

This package provides a PHP enum for the log level to simplify things. Hopefully the PSR-3 package will provide this itself at some point in the future.

You will likely want to take advantage of one of the following additional logging packages that make use of this package.

- [PostgreSQL Logger](https://github.com/programster/package-pgsql-logger)- log to a PostgreSQL database.
- [MySQL Logger](https://github.com/programster/package-mysql-logger) - log to a MySQL database.
- [Email Logger](https://github.com/programster/package-email-logger) - send logs to any number of email addresses.

Install
-------

[](#install)

```
composer require programster/log
```

Example Usage
-------------

[](#example-usage)

```
/**
 * Get a logger for logging all the things.
 * @return \Psr\Log\LoggerInterface
 */
public function getLogger() : \Psr\Log\LoggerInterface
{
    return new \Programster\Log\FileLogger(filepath: "/path/to/my/logs.csv");
}
```

###  Health Score

51

—

FairBetter than 96% of packages

Maintenance86

Actively maintained with recent releases

Popularity18

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity75

Established project with proven stability

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

Recently: every ~481 days

Total

10

Last Release

66d ago

Major Versions

1.2.3 → 2.0.02023-04-25

PHP version history (3 changes)1.0.0PHP &gt;=7.2.0

2.0.0PHP &gt;=8.1.0

2.1.0PHP &gt;=8.2.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/64a048ca8be761aced9419279975a21ef679b71c70d8263bc2fc413a87ad381c?d=identicon)[programster](/maintainers/programster)

---

Top Contributors

[![programster](https://avatars.githubusercontent.com/u/5709838?v=4)](https://github.com/programster "programster (26 commits)")

---

Tags

loglogging

### Embed Badge

![Health badge](/badges/programster-log/health.svg)

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

###  Alternatives

[monolog/monolog

Sends your logs to files, sockets, inboxes, databases and various web services

21.4k964.9M7.0k](/packages/monolog-monolog)[sentry/sentry

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

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

Fast, flexible, easy PSR-3-compatible PHP logging package with dozens of handlers.

3451.5M24](/packages/analog-analog)[league/tactician-logger

Adds PSR-3 logging support to the Tactician command bus

649.6M9](/packages/league-tactician-logger)[nelmio/js-logger-bundle

Adds logging of JS errors in your Symfony application

1761.2M](/packages/nelmio-js-logger-bundle)[inpsyde/wonolog

Monolog-based logging package for WordPress.

183617.9k7](/packages/inpsyde-wonolog)

PHPackages © 2026

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