PHPackages                             tarfin-labs/laravel-cloudwatch-logger - 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. tarfin-labs/laravel-cloudwatch-logger

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

tarfin-labs/laravel-cloudwatch-logger
=====================================

Laravel logger for AWS Clouldwatch Log service.

v2.7.0(1y ago)20160.7k↓21.6%4[1 issues](https://github.com/tarfin-labs/laravel-cloudwatch-logger/issues)MITPHPPHP ^7.3|^8.0|^8.1|^8.2|^8.3|^8.4

Since Jul 15Pushed 1y ago6 watchersCompare

[ Source](https://github.com/tarfin-labs/laravel-cloudwatch-logger)[ Packagist](https://packagist.org/packages/tarfin-labs/laravel-cloudwatch-logger)[ Docs](https://github.com/tarfin-labs/laravel-cloudwatch-logger)[ RSS](/packages/tarfin-labs-laravel-cloudwatch-logger/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (9)Dependencies (4)Versions (17)Used By (0)

Laravel Logger for AWS CloudWatch
=================================

[](#laravel-logger-for-aws-cloudwatch)

Laravel logger factory for AWS Cloudwatch Logs service.

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

[](#installation)

You can install the package via composer:

```
composer require tarfin-labs/laravel-cloudwatch-logger
```

Usage
-----

[](#usage)

Config parameters for logging are defined at `config/logging.php`.

You need to add new channel as `cloudwatch` and copy params inside `config/config.php` into it.

```
'channels' => [
    ...

    'cloudwatch' => [
        'driver' => 'custom',
        'via' => \TarfinLabs\LaravelCloudWatchLogger\LaravelCloudWatchLoggerFactory::class,
        'aws' => [
            'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
            'version' => 'latest',
            'credentials' => [
                'key' => env('AWS_ACCESS_KEY_ID'),
                'secret' => env('AWS_SECRET_ACCESS_KEY'),
            ],
        ],
        'name' => env('CLOUDWATCH_LOG_NAME', ''),
        'group' => env('CLOUDWATCH_LOG_GROUP_NAME', env('APP_NAME') . '-' . env('APP_ENV')),
        'stream' => env('CLOUDWATCH_LOG_STREAM', 'default'),
        'retention' => env('CLOUDWATCH_LOG_RETENTION', 7),
        'level' => env('CLOUDWATCH_LOG_LEVEL', 'error'),
        'extra' => [        // In case there's extra information to be logged
            'env' => env('APP_ENV'),
            'php' => PHP_VERSION,
            'laravel' => app()->version(),
        ],
    ],
],
```

Change the log channel inside `.env` file with `cloudwatch`.

```
LOG_CHANNEL=cloudwatch
```

You can use Laravel's default `Log` class to send your logs to CloudWatch.

```
\Illuminate\Support\Facades\Log::info('user logged in successfully', [
    'id' => 1,
    'username' => 'JohnDoe',
    'ip' => '127.0.0.1',
]);
```

### Testing

[](#testing)

```
composer test
```

### Changelog

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

### Security

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Turan Karatuğ](https://github.com/tkaratug)
- [Faruk Can](https://github.com/frkcn)
- [Yunus Emre Deligöz](https://github.com/deligoez)
- [Hakan Özdemir](https://github.com/hozdemir)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

51

—

FairBetter than 96% of packages

Maintenance42

Moderate activity, may be stable

Popularity44

Moderate usage in the ecosystem

Community17

Small or concentrated contributor base

Maturity81

Battle-tested with a long release history

 Bus Factor2

2 contributors hold 50%+ of commits

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

Recently: every ~185 days

Total

9

Last Release

448d ago

Major Versions

v1.0.0 → v2.0.02020-10-06

PHP version history (7 changes)v1.0.0PHP ^7.2

v2.0.0PHP ^7.3

v2.1.0PHP ^7.3 || ^8.0

v2.2.0PHP ^7.3|^8.0|^8.1

v2.4.0PHP ^7.3|^8.0|^8.1|^8.2

v2.6.0PHP ^7.3|^8.0|^8.1|^8.2|^8.3

v2.7.0PHP ^7.3|^8.0|^8.1|^8.2|^8.3|^8.4

### Community

Maintainers

![](https://www.gravatar.com/avatar/50dc98a0c75a1aaba61d52bb073e1b0cbdb17f4d5ed4bd1c694c71784b088e16?d=identicon)[tkaratug](/maintainers/tkaratug)

---

Top Contributors

[![tkaratug](https://avatars.githubusercontent.com/u/4394344?v=4)](https://github.com/tkaratug "tkaratug (9 commits)")[![YunusEmreNalbant](https://avatars.githubusercontent.com/u/29780061?v=4)](https://github.com/YunusEmreNalbant "YunusEmreNalbant (7 commits)")[![frkcn](https://avatars.githubusercontent.com/u/374634?v=4)](https://github.com/frkcn "frkcn (5 commits)")[![deligoez](https://avatars.githubusercontent.com/u/3030815?v=4)](https://github.com/deligoez "deligoez (1 commits)")[![erashdan](https://avatars.githubusercontent.com/u/16059897?v=4)](https://github.com/erashdan "erashdan (1 commits)")

---

Tags

laravelcloudwatchtarfin-labslaravel-cloudwatch-logger

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/tarfin-labs-laravel-cloudwatch-logger/health.svg)

```
[![Health](https://phpackages.com/badges/tarfin-labs-laravel-cloudwatch-logger/health.svg)](https://phpackages.com/packages/tarfin-labs-laravel-cloudwatch-logger)
```

###  Alternatives

[spatie/laravel-health

Monitor the health of a Laravel application

86910.0M83](/packages/spatie-laravel-health)[rollbar/rollbar-laravel

Rollbar error monitoring integration for Laravel projects

14110.4M7](/packages/rollbar-rollbar-laravel)[yadahan/laravel-authentication-log

Laravel Authentication Log provides authentication logger and notification for Laravel.

416632.8k5](/packages/yadahan-laravel-authentication-log)[kitloong/laravel-app-logger

Laravel log for your application

101.2M8](/packages/kitloong-laravel-app-logger)[shaffe/laravel-mail-log-channel

A package to support logging via email in Laravel

1286.2k](/packages/shaffe-laravel-mail-log-channel)[kssadi/log-tracker

A powerful, intuitive, and efficient log viewer for Laravel applications.

264.8k](/packages/kssadi-log-tracker)

PHPackages © 2026

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