PHPackages                             khantzawhein/laravel-cloudwatch-logs - 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. khantzawhein/laravel-cloudwatch-logs

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

khantzawhein/laravel-cloudwatch-logs
====================================

Laravel Adapter for AWS CloudWatch Which Works

0.2.5(5y ago)064MITPHP

Since Aug 1Pushed 5y agoCompare

[ Source](https://github.com/khantzawhein/laravel-cloudwatch-logs)[ Packagist](https://packagist.org/packages/khantzawhein/laravel-cloudwatch-logs)[ RSS](/packages/khantzawhein-laravel-cloudwatch-logs/feed)WikiDiscussions master Synced 2d ago

READMEChangelog (3)Dependencies (5)Versions (19)Used By (0)

Logger for Aws Cloud Watch
--------------------------

[](#logger-for-aws-cloud-watch)

### Installation

[](#installation)

`composer require pagevamp/laravel-cloudwatch-logs`

### Example

[](#example)

You can use laravel's default `\Log` class to use this

`\Log::info('user logged in', ['id' => 123, 'name' => 'Naren']);`

### Config

[](#config)

Config for logging is defined at `config/logging.php`. Add `cloudwatch` to the `channels` array

```
'channels' =>  [
    'cloudwatch' => [
            'driver' => 'custom',
            'name' => env('CLOUDWATCH_LOG_NAME', ''),
            'region' => env('CLOUDWATCH_LOG_REGION', ''),
            'credentials' => [
                'key' => env('CLOUDWATCH_LOG_KEY', ''),
                'secret' => env('CLOUDWATCH_LOG_SECRET', '')
            ],
            'stream_name' => env('CLOUDWATCH_LOG_STREAM_NAME', 'laravel_app'),
            'retention' => env('CLOUDWATCH_LOG_RETENTION_DAYS', 14),
            'group_name' => env('CLOUDWATCH_LOG_GROUP_NAME', 'laravel_app'),
            'version' => env('CLOUDWATCH_LOG_VERSION', 'latest'),
            'formatter' => \Monolog\Formatter\JsonFormatter::class,
            'disabled' => env('DISABLE_CLOUDWATCH_LOG', false),
            'via' => \Pagevamp\Logger::class
        ],
]

```

Add correct values to keys in your `.env` file. And it should work.

If the role of your AWS EC2 instance has access to Cloudwatch logs, `CLOUDWATCH_LOG_KEY` and `CLOUDWATCH_LOG_SECRET` need not be defined in your `.env` file.

### Add To Project

[](#add-to-project)

#### Laravel 5.5 or Higher

[](#laravel-55-or-higher)

This package uses laravel's [Package discovery](https://laravel.com/docs/5.6/packages#package-discovery). To disable this package by default you can add `DISABLE_CLOUDWATCH_LOG=true` to you local `.env` file and this package will be disabled.

#### Laravel 5.4 or Lower

[](#laravel-54-or-lower)

Add to the `providers` array in `config/app.php`:

```
Pagevamp\Providers\CloudWatchServiceProvider::class

```

### Concept

[](#concept)

This package relies on laravel's listener for log events. This package DOES NOT replace the default logging, instead adds additional log to AWS CLoud Watch. Hence you do not have to change the default log driver to make this work.

### Contribution

[](#contribution)

I have added a `pre-commit` hook to run `php-cs-fixer` whenever you make a commit. To enable this run `sh hooks.sh`.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity61

Established project with proven stability

 Bus Factor1

Top contributor holds 62.8% 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 ~68 days

Recently: every ~79 days

Total

15

Last Release

1888d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/21118943?v=4)[Khant Zaw Hein](/maintainers/khantzawhein)[@khantzawhein](https://github.com/khantzawhein)

---

Top Contributors

[![developernaren](https://avatars.githubusercontent.com/u/3628468?v=4)](https://github.com/developernaren "developernaren (27 commits)")[![khantzawhein](https://avatars.githubusercontent.com/u/21118943?v=4)](https://github.com/khantzawhein "khantzawhein (8 commits)")[![FoxxMD](https://avatars.githubusercontent.com/u/4663766?v=4)](https://github.com/FoxxMD "FoxxMD (4 commits)")[![rmundel](https://avatars.githubusercontent.com/u/13142574?v=4)](https://github.com/rmundel "rmundel (2 commits)")[![naveenk87](https://avatars.githubusercontent.com/u/7149360?v=4)](https://github.com/naveenk87 "naveenk87 (1 commits)")[![niekvanderkooy](https://avatars.githubusercontent.com/u/1261369?v=4)](https://github.com/niekvanderkooy "niekvanderkooy (1 commits)")

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/khantzawhein-laravel-cloudwatch-logs/health.svg)

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

###  Alternatives

[spatie/laravel-health

Monitor the health of a Laravel application

85810.0M83](/packages/spatie-laravel-health)[beyondcode/laravel-server-timing

Add Server-Timing header information from within your Laravel apps.

5712.0M1](/packages/beyondcode-laravel-server-timing)[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)[label84/laravel-auth-log

Log user authentication actions in Laravel.

3654.0k](/packages/label84-laravel-auth-log)[shaffe/laravel-mail-log-channel

A package to support logging via email in Laravel

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

PHPackages © 2026

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