PHPackages                             alirezasedghi/laravel-image-faker - 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. [Image &amp; Media](/categories/media)
4. /
5. alirezasedghi/laravel-image-faker

ActiveLaravel[Image &amp; Media](/categories/media)

alirezasedghi/laravel-image-faker
=================================

A library to generate fake images for Laravel

v1.0(3y ago)1623.2k↓27.5%2[2 issues](https://github.com/AlirezaSedghi/laravel-image-faker/issues)2MITPHPPHP &gt;=8.0.0

Since May 3Pushed 2y ago1 watchersCompare

[ Source](https://github.com/AlirezaSedghi/laravel-image-faker)[ Packagist](https://packagist.org/packages/alirezasedghi/laravel-image-faker)[ Docs](https://github.com/AlirezaSedghi/laravel-image-faker)[ RSS](/packages/alirezasedghi-laravel-image-faker/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (2)DependenciesVersions (3)Used By (2)

Laravel Image Faker
===================

[](#laravel-image-faker)

 ![Required PHP Version](https://camo.githubusercontent.com/2d1d30d3c307e293f90e4a610b56d0705014e3821abfb741c0437444e7e8816b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7068702d3e3d382e302e302d626c75653f7374796c653d666c61742d737175617265) [![Total Downloads](https://camo.githubusercontent.com/4a4366dec0b55e4caeae2401cb970834a6dabaa101fbd3acf47b530d188e8d7f/68747470733a2f2f706f7365722e707567782e6f72672f616c6972657a617365646768692f6c61726176656c2d696d6167652d66616b65722f646f776e6c6f6164733f7374796c653d666c61742d737175617265)](https://packagist.org/packages/alirezasedghi/laravel-image-faker) [![Latest Stable Version](https://camo.githubusercontent.com/f49757d9cfe76f45c282a2168df284ed6b212821718248ce7b91f04ce19abb6b/68747470733a2f2f706f7365722e707567782e6f72672f616c6972657a617365646768692f6c61726176656c2d696d6167652d66616b65722f762f737461626c653f7374796c653d666c61742d737175617265)](https://packagist.org/packages/alirezasedghi/laravel-image-faker) [![Latest Stable Version](https://camo.githubusercontent.com/a00f2d8be8b45cfa14f50e795025537efc44c1f5b515956809e86aded543b4ca/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f72656c656173652f416c6972657a615365646768692f6c61726176656c2d696d6167652d66616b65723f7374796c653d666c61742d737175617265)](https://github.com/AlirezaSedghi/laravel-image-faker/releases) [![License](https://camo.githubusercontent.com/942e017bf0672002dd32a857c95d66f28c5900ab541838c6c664442516309c8a/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d626c75652e7376673f7374796c653d666c61742d737175617265)](https://raw.githubusercontent.com/AlirezaSedghi/laravel-image-faker/master/LICENSE) [![GitHub issues](https://camo.githubusercontent.com/fb74c1b2a356059921a26e132990c4aa9e02e3b7ccadab53387a3879b11b8c1a/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6973737565732f416c6972657a615365646768692f6c61726176656c2d696d6167652d66616b65722e7376673f7374796c653d666c61742d737175617265)](https://github.com/AlirezaSedghi/laravel-image-faker/issues)

Description
-----------

[](#description)

Laravel Image Faker is an alternative image provider for [FakerPHP](https://github.com/FakerPHP/Faker).

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

[](#installation)

```
composer require alirezasedghi/laravel-image-faker
```

Resources
---------

[](#resources)

The following sources are utilized by this project to create random images:

- [Lorem Picsum](https://picsum.photos/)
- [LoremFlickr](https://loremflickr.com/)
- [PlaceDog](https://placedog.net/)
- [Kittens (Random Cats) by TheOldReader.com](https://theoldreader.com/kittens/)
- [Fake People by BoredHumans.com](https://boredhumans.com/faces.php)

Methods
-------

[](#methods)

CodeDescription`(new ImageFaker(new Service()))->imageUrl()`Return a random image url from the specified service`(new ImageFaker(new Service()))->image()`Download a random image from the specified serviceUsage
-----

[](#usage)

```
/**
 * Define the model's default state.
 *
 * @return array
 */
public function definition(): array
{
    /**
     * In order to utilize other services, the following substitutes can be used:
     *  - new ImageFaker(new LoremFlickr());
     *  - new ImageFaker(new PlaceDog());
     *  - new ImageFaker(new Kittens());
     *  - new ImageFaker(new FakePeople());
     */
    $imageFaker = new ImageFaker(new Picsum());

    return [
        'title' => $this->faker->sentence(),
        'content' => $this->faker->paragraph(),
        'attachments' => $imageFaker->image( storage_path("app/attachments/") )
    ];
}
```

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

[](#contributing)

Don't hesitate to send a PR if you're looking for a service that's not available in this package. 😁

License
-------

[](#license)

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

###  Health Score

33

—

LowBetter than 75% of packages

Maintenance18

Infrequent updates — may be unmaintained

Popularity36

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 85.7% 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 ~0 days

Total

2

Last Release

1110d ago

Major Versions

v0.9 → v1.02023-05-04

### Community

Maintainers

![](https://www.gravatar.com/avatar/776d857905afc82f582e4d843ae3e26821e37bc7c586a2e2d1c24aa86b6ece5a?d=identicon)[AlirezaSedghi](/maintainers/AlirezaSedghi)

---

Top Contributors

[![AlirezaSedghi](https://avatars.githubusercontent.com/u/8061051?v=4)](https://github.com/AlirezaSedghi "AlirezaSedghi (6 commits)")[![loglinn05](https://avatars.githubusercontent.com/u/78077184?v=4)](https://github.com/loglinn05 "loglinn05 (1 commits)")

---

Tags

fakerimagelaravelphprandom-imagephplaravelimagefakerrandom-imagelaravel-fakerimage-faker

### Embed Badge

![Health badge](/badges/alirezasedghi-laravel-image-faker/health.svg)

```
[![Health](https://phpackages.com/badges/alirezasedghi-laravel-image-faker/health.svg)](https://phpackages.com/packages/alirezasedghi-laravel-image-faker)
```

###  Alternatives

[tomatophp/filament-media-manager

Manage your media files using spatie media library with easy to use GUI for FilamentPHP

14543.9k3](/packages/tomatophp-filament-media-manager)[nikkanetiya/laravel-color-palette

Laravel Wrapper for `ksubileau/color-thief-php`. Grabs the dominant color or a representative color palette from an image. Uses PHP and GD or Imagick.

3312.6k](/packages/nikkanetiya-laravel-color-palette)

PHPackages © 2026

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