PHPackages                             elegantly/filament-kpi - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. elegantly/filament-kpi

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

elegantly/filament-kpi
======================

Plugin for elegantly/laravel-kpi

v5.0.0(3mo ago)22.7k↓30%[2 PRs](https://github.com/ElegantEngineeringTech/filament-kpi/pulls)MITPHPPHP ^8.2CI passing

Since Sep 17Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/ElegantEngineeringTech/filament-kpi)[ Packagist](https://packagist.org/packages/elegantly/filament-kpi)[ Docs](https://github.com/elegantengineeringtech/filament-kpi)[ GitHub Sponsors](https://github.com/ElegantEngineeringTech)[ RSS](/packages/elegantly-filament-kpi/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)Dependencies (13)Versions (7)Used By (0)

Plugin for elegantly/laravel-kpi
================================

[](#plugin-for-elegantlylaravel-kpi)

[![Latest Version on Packagist](https://camo.githubusercontent.com/dc7a5cae469bf7557687731c32e5e99653b9f650994f6664a57c03bd13629c87/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f656c6567616e746c792f66696c616d656e742d6b70692e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/elegantly/filament-kpi)[![GitHub Tests Action Status](https://camo.githubusercontent.com/801bd8470e748465a34d1b3f899df98f43b8c70b0ad08850c1d979a92c3cce7d/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f656c6567616e74656e67696e656572696e67746563682f66696c616d656e742d6b70692f72756e2d74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/elegantengineeringtech/filament-kpi/actions?query=workflow%3Arun-tests+branch%3Amain)[![GitHub Code Style Action Status](https://camo.githubusercontent.com/3717a92b5c8a3910810862b2351c522160dfe433584844901ef6c621bb0ccf6e/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f656c6567616e74656e67696e656572696e67746563682f66696c616d656e742d6b70692f6669782d7068702d636f64652d7374796c696e672e796d6c3f6272616e63683d6d61696e266c6162656c3d636f64652532307374796c65267374796c653d666c61742d737175617265)](https://github.com/elegantengineeringtech/filament-kpi/actions?query=workflow%3A%22Fix+PHP+code+styling%22+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/9249b0213372ee6e868f74c0865d7f186ca4eb65de468676bcad2c1ca9245b8a/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f656c6567616e746c792f66696c616d656e742d6b70692e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/elegantly/filament-kpi)

This plugin allows you to create charts and stats using [`elegantly/laravel-kpi`](https://github.com/ElegantEngineeringTech/laravel-kpi) like this:

```
use Elegantly\FilamentKpi\Widgets\KpiStat;
use App\Kpis\Users\UsersCountKpi;

KpiStat::kpi(UsersCountKpi::class);
```

```
class UsersChart extends KpiChart
{
    protected static string $kpi = UsersCountKpi::class;
}
```

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

[](#installation)

You can install the package via composer:

```
composer require elegantly/filament-kpi
```

Usage
-----

[](#usage)

### Display a Kpi Stat

[](#display-a-kpi-stat)

```
namespace App\Filament\Resources\UserResource\Widgets;

use Elegantly\FilamentKpi\Widgets\KpiStat;
use App\Kpis\Users\UsersCountKpi;
use Filament\Widgets\StatsOverviewWidget;

class UsersStatsOverview extends StatsOverviewWidget
{
    protected static ?string $pollingInterval = null;

    protected function getCards(): array
    {
        return [
            KpiStat::kpi(
                definition: UsersCountKpi::class,
                interval: KpiInterval::Day, // (optional) default to UsersCountKpi::getSnapshotInterval()
                diff: true, // (optional) default to is_subclass_of(UsersCountKpi::class, HasDifference::class)
            ),
        ];
    }
}
```

### Display a Kpi Chart

[](#display-a-kpi-chart)

```
namespace App\Filament\Resources\UserResource\Widgets;

use Elegantly\FilamentKpi\Widgets\KpiChart;
use App\Kpis\Users\UsersCountKpi;

class UsersChart extends KpiChart
{
    protected static string $kpi = UsersCountKpi::class;
}
```

Testing
-------

[](#testing)

```
composer test
```

Changelog
---------

[](#changelog)

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

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

[](#contributing)

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

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

Please review [our security policy](../../security/policy) on how to report security vulnerabilities.

Credits
-------

[](#credits)

- [Quentin Gabriele](https://github.com/QuentinGab)
- [All Contributors](../../contributors)

License
-------

[](#license)

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

###  Health Score

46

—

FairBetter than 93% of packages

Maintenance84

Actively maintained with recent releases

Popularity23

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity56

Maturing project, gaining track record

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

Total

5

Last Release

113d ago

Major Versions

v1.0.0 → 4.x-dev2025-08-04

v4.0.1 → v5.0.02026-01-18

### Community

Maintainers

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

---

Top Contributors

[![QuentinGab](https://avatars.githubusercontent.com/u/40128136?v=4)](https://github.com/QuentinGab "QuentinGab (12 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (9 commits)")[![github-actions[bot]](https://avatars.githubusercontent.com/in/15368?v=4)](https://github.com/github-actions[bot] "github-actions[bot] (5 commits)")

---

Tags

laravelElegantEngineeringTechfilament-kpi

###  Code Quality

TestsPest

Static AnalysisPHPStan

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/elegantly-filament-kpi/health.svg)

```
[![Health](https://phpackages.com/badges/elegantly-filament-kpi/health.svg)](https://phpackages.com/packages/elegantly-filament-kpi)
```

###  Alternatives

[guava/calendar

Adds support for vkurko/calendar to Filament PHP.

298241.0k3](/packages/guava-calendar)[bezhansalleh/filament-google-analytics

Google Analytics integration for FilamentPHP

205144.8k5](/packages/bezhansalleh-filament-google-analytics)[jibaymcs/filament-tour

Bring the power of DriverJs to your Filament panels and start a tour !

12247.8k](/packages/jibaymcs-filament-tour)[marcelweidum/filament-expiration-notice

Customize the livewire expiration notice

9169.0k4](/packages/marcelweidum-filament-expiration-notice)[hydrat/filament-table-layout-toggle

Filament plugin adding a toggle button to tables, allowing user to switch between Grid and Table layouts.

6292.3k1](/packages/hydrat-filament-table-layout-toggle)[outerweb/filament-settings

Filament integration for the outerweb/settings package

3690.9k4](/packages/outerweb-filament-settings)

PHPackages © 2026

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