PHPackages                             saade/filament-facehash - 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. saade/filament-facehash

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

saade/filament-facehash
=======================

Use Facehash as the default avatar provider in your Filament panels.

v1.0.1(1mo ago)48.1k↓18.9%[2 PRs](https://github.com/saade/filament-facehash/pulls)MITPHPPHP ^8.2CI passing

Since Feb 17Pushed 3w agoCompare

[ Source](https://github.com/saade/filament-facehash)[ Packagist](https://packagist.org/packages/saade/filament-facehash)[ GitHub Sponsors](https://github.com/saade)[ RSS](/packages/saade-filament-facehash/feed)WikiDiscussions main Synced 2w ago

READMEChangelog (2)Dependencies (6)Versions (3)Used By (0)

Filament Facehash
=================

[](#filament-facehash)

[![Facehash](art/cover.png)](art/cover.png)

Generate unique, deterministic avatar faces for your Filament panels. Drop-in replacement for default user avatars — same name always produces the same face. Pure SVG, no GD or Imagick required.

[Try the playground](https://facehash.saade.dev)

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

[](#installation)

```
composer require saade/filament-facehash
```

Usage
-----

[](#usage)

Add the provider and plugin to your panel configuration:

```
use Saade\FilamentFacehash\FacehashPlugin;
use Saade\FilamentFacehash\FacehashProvider;

public function panel(Panel $panel): Panel
{
    return $panel
        ->defaultAvatarProvider(FacehashProvider::class)
        ->plugins([
            FacehashPlugin::make(),
        ]);
}
```

Configuration
-------------

[](#configuration)

Customize the avatars using the plugin's fluent API:

```
use Saade\Facehash\Enums\Variant;
use Saade\FilamentFacehash\FacehashPlugin;

FacehashPlugin::make()
    ->size(40)                       // Avatar size in pixels (default: 40)
    ->variant(Variant::Gradient)     // Variant::Gradient or Variant::Solid (default: Gradient)
    ->initial(true)                  // Show first letter of name (default: true)
    ->colors([                       // Custom color palette
        '#ec4899',
        '#f59e0b',
        '#3b82f6',
        '#f97316',
        '#10b981',
    ])
```

For more configuration options (routes, default overrides, etc.), visit the [Facehash package documentation](https://github.com/saade/facehash).

Model Trait
-----------

[](#model-trait)

For using facehash avatars outside of Filament panels (e.g. in Blade views, notifications), add the trait to your User model:

```
use Saade\FilamentFacehash\Concerns\HasFacehashAvatar;

class User extends Authenticatable
{
    use HasFacehashAvatar;
}
```

This gives you:

```
$user->facehash_avatar_url  // data:image/svg+xml;base64,...
```

Override which attribute is used as the avatar name:

```
use Illuminate\Database\Eloquent\Casts\Attribute;

public function facehashAvatarName(): Attribute
{
    return new Attribute(
        get: fn () => $this->email  // use email instead of name
    );
}
```

Credits
-------

[](#credits)

- [Facehash for Laravel](https://github.com/saade/facehash) — the underlying PHP/Laravel package
- [Facehash](https://facehash.dev) by [Cossistant](https://github.com/cossistantcom/cossistant) — the original JavaScript library

License
-------

[](#license)

MIT

###  Health Score

48

—

FairBetter than 94% of packages

Maintenance94

Actively maintained with recent releases

Popularity29

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

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

Total

2

Last Release

36d ago

### Community

Maintainers

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

---

Top Contributors

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

---

Tags

laravelsvgavatarfilamentfilamentphpdeterministicfacehash

### Embed Badge

![Health badge](/badges/saade-filament-facehash/health.svg)

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

###  Alternatives

[rawilk/profile-filament-plugin

Profile &amp; MFA starter kit for filament.

3915.5k](/packages/rawilk-profile-filament-plugin)[backstage/mails

View logged mails and events in a beautiful Filament UI.

16429.7k](/packages/backstage-mails)[marcelweidum/filament-passkeys

Use passkeys in your filamentphp app

6758.2k2](/packages/marcelweidum-filament-passkeys)[stephenjude/filament-two-factor-authentication

Filament Two Factor Authentication: Google 2FA + Passkey Authentication

85240.3k9](/packages/stephenjude-filament-two-factor-authentication)[relaticle/custom-fields

User Defined Custom Fields for Laravel Filament

16461.2k](/packages/relaticle-custom-fields)[marcelweidum/filament-expiration-notice

Customize the livewire expiration notice

94160.6k6](/packages/marcelweidum-filament-expiration-notice)

PHPackages © 2026

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