PHPackages                             mdrobbins/fakerphp-picsum-images - 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. mdrobbins/fakerphp-picsum-images

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

mdrobbins/fakerphp-picsum-images
================================

Alternative image provider for fakerphp using picsum.photos

05PHP

Since Sep 23Pushed 1y agoCompare

[ Source](https://github.com/mdrobbins/fakerphp-picsum-images)[ Packagist](https://packagist.org/packages/mdrobbins/fakerphp-picsum-images)[ RSS](/packages/mdrobbins-fakerphp-picsum-images/feed)WikiDiscussions main Synced yesterday

READMEChangelogDependenciesVersions (1)Used By (0)

Fakerphp Picsum Images
======================

[](#fakerphp-picsum-images)

[![Latest Version on Packagist](https://camo.githubusercontent.com/e26d67b2f17fb118ee454ceaf97f6df496264bc1c5e9ecc42278d7f217092f3b/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f736d6b6e7374642f66616b65727068702d70696373756d2d696d616765732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/smknstd/fakerphp-picsum-images)[![GitHub Tests Action Status](https://camo.githubusercontent.com/885f02191f05ed96ba3981562ed5caaaecc1bc032cacc70c46ac2fcd4f0dbd4c/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f736d6b6e7374642f66616b65727068702d70696373756d2d696d616765732f72756e2d74657374732e796d6c3f6272616e63683d6d61696e)](https://github.com/smknstd/fakerphp-picsum-images/actions?query=workflow%3ATests+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/d6b8912b7e8d6907dea0e0444f5d6e012fced85bf74d7c3a3d16590ff9a36653/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f736d6b6e7374642f66616b65727068702d70696373756d2d696d616765732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/smknstd/fakerphp-picsum-images)

Introduction
------------

[](#introduction)

Alternative image provider for [fakerphp](https://github.com/fakerphp/faker) using [picsum.photos](https://picsum.photos)

*This package has been forked from [mmo/faker-images](https://github.com/morawskim/faker-images) for [fzaninotto/faker](https://github.com/fzaninotto/Faker) (deprecated [~ Oct 2020](https://marmelab.com/blog/2020/10/21/sunsetting-faker.html)).*

Ressources
----------

[](#ressources)

- [Tutorial for laravel](https://smknstd.medium.com/fake-beautiful-images-in-laravel-51062967d1db)

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

[](#installation)

You can install the package via composer in dev dependency section:

```
composer require --dev smknstd/fakerphp-picsum-images
```

Usage
-----

[](#usage)

```
$faker = \Faker\Factory::create();
$faker->addProvider(new \Smknstd\FakerPicsumImages\FakerPicsumImagesProvider($faker));

// return a string that contains a url like 'https://picsum.photos/800/600/'
$faker->imageUrl(width: 800, height: 600);

// return a string that contains a url which returns the same random image based on the provided seed
$filePath= $faker->image(width: 800, height: 800, seed: 'useremail@example.com');

// download a properly sized image from picsum into a file with a file path like '/tmp/13b73edae8443990be1aa8f1a483bc27.jpg'
$filePath= $faker->image(dir: '/tmp', width: 640, height: 480);
```

Also, there are some more options :

- alternative webp format
- effects (grayscale, blurry)
- seeding ensures you can get the same photo each time by providing a seed string
- returning a specific photo based on an id instead of a random one (ex: )

Testing
-------

[](#testing)

```
composer test
```

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)

- [Arnaud Becher](https://github.com/smknstd)
- [Marcin Morawski ](https://github.com/morawskim)

License
-------

[](#license)

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

###  Health Score

14

—

LowBetter than 1% of packages

Maintenance28

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity17

Early-stage or recently created project

 Bus Factor1

Top contributor holds 95.2% 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.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1900892?v=4)[Mike Robbins](/maintainers/mdrobbins)[@mdrobbins](https://github.com/mdrobbins)

---

Top Contributors

[![smknstd](https://avatars.githubusercontent.com/u/2412608?v=4)](https://github.com/smknstd "smknstd (20 commits)")[![mdrobbins](https://avatars.githubusercontent.com/u/1900892?v=4)](https://github.com/mdrobbins "mdrobbins (1 commits)")

### Embed Badge

![Health badge](/badges/mdrobbins-fakerphp-picsum-images/health.svg)

```
[![Health](https://phpackages.com/badges/mdrobbins-fakerphp-picsum-images/health.svg)](https://phpackages.com/packages/mdrobbins-fakerphp-picsum-images)
```

###  Alternatives

[temporal-php/support

Helpers that simplify working with the Temporal PHP SDK

1217.1k](/packages/temporal-php-support)[chalcedonyt/laravel-specification

Implementation of the specification pattern

128.7k](/packages/chalcedonyt-laravel-specification)

PHPackages © 2026

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