asbiin/laravel-adorable is a Laravel package for generate an adorable avatar for laravel.
It currently has 4 GitHub stars and 77.175 downloads on Packagist (latest version 1.3.0).
Install it with composer require asbiin/laravel-adorable.
Discover more Laravel packages by asbiin
or browse all Laravel packages to compare alternatives.
Last updated
LaravelAdorable is an library to generate nice avatars on Laravel.

You may use Composer to install this package into your Laravel project:
composer require asbiin/laravel-adorable
You don't need to add this package to your service providers.
This package supports Laravel 8 and newer, and has been tested with php 7.4 and newer versions.
You can publish the LaravelAdorable configuration in a file named config/adorable.php.
Just run this artisan command:
php artisan vendor:publish --tag="laraveladorable-config"
This package depends on intervention/image. It requires one of the following image libraries:
You can configure the image library to use in the driver setting of the config/adorable.php file.
Use LaravelAdorable facade to generate avatar:
use Illuminate\Support\Str;
use LaravelAdorable\Facades\LaravelAdorable;
…
$size = 200;
$hash = Str::uuid()->toString();
$dataUrl = LaravelAdorable::get($size, $hash);
// $dataUrl: "data:image/png;base64,..."
This generates a base64 data-url content, like data:image/png;base64,….
You can display a data-url in html with:
<img src="{{ $dataUrl }}" alt="avatar" />
Author: Alexis Saettler
Copyright © 2022.
Licensed under the MIT License. View license.
This work is mainly inspired by itsthatguy/avatars-api-middleware (MIT License).
Images resources are Copyright (c) 2014 Adorable IO LLC.