PHPackages                             armezit/spatie-image - 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. armezit/spatie-image

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

armezit/spatie-image
====================

Manipulate images with an expressive API

2.2.4(3y ago)05MITPHPPHP ^8.0

Since Sep 12Pushed 3y agoCompare

[ Source](https://github.com/armezit/spatie-image)[ Packagist](https://packagist.org/packages/armezit/spatie-image)[ Docs](https://github.com/spatie/image)[ Fund](https://spatie.be/open-source/support-us)[ GitHub Sponsors](https://github.com/spatie)[ RSS](/packages/armezit-spatie-image/feed)WikiDiscussions main Synced today

READMEChangelog (1)Dependencies (8)Versions (2)Used By (0)

[![](https://camo.githubusercontent.com/2bedf63f24cda7efab02da955dc11fb7ef8a060e2f26b73c33a7aac84529b8a3/68747470733a2f2f6769746875622d6164732e73332e65752d63656e7472616c2d312e616d617a6f6e6177732e636f6d2f737570706f72742d756b7261696e652e7376673f743d31)](https://supportukrainenow.org)

Manipulate images with an expressive API
========================================

[](#manipulate-images-with-an-expressive-api)

[![Latest Version on Packagist](https://camo.githubusercontent.com/8da89803d676423a7562f8a023f69945463b6cbe2674f3661d0c6d3f444568a1/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7370617469652f696d6167652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/spatie/image)[![MIT Licensed](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![GitHub Workflow Status](https://camo.githubusercontent.com/5c7cd8908c20897797bdafb84000bf68b90dba3e39e03c75b6063a22660b2cfb/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f776f726b666c6f772f7374617475732f7370617469652f696d6167652f72756e2d74657374733f6c6162656c3d7465737473)](https://camo.githubusercontent.com/5c7cd8908c20897797bdafb84000bf68b90dba3e39e03c75b6063a22660b2cfb/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f776f726b666c6f772f7374617475732f7370617469652f696d6167652f72756e2d74657374733f6c6162656c3d7465737473)[![Total Downloads](https://camo.githubusercontent.com/8015cb6b82caf47ee25a54a3aa210a820f15307dd3e8c93dc56220aa8933ed21/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7370617469652f696d6167652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/spatie/image)

Image manipulation doesn't have to be hard. Here are a few examples on how this package makes it very easy to manipulate images.

```
use Spatie\Image\Image;

// modifying the image so it fits in a 100x100 rectangle without altering aspect ratio
Image::load($pathToImage)
   ->width(100)
   ->height(100)
   ->save($pathToNewImage);

// overwriting the original image with a greyscale version
Image::load($pathToImage)
   ->greyscale()
   ->save();

// make image darker and save it in low quality
Image::load($pathToImage)
   ->brightness(-30)
   ->quality(25)
   ->save();

// rotate the image and sharpen it
Image::load($pathToImage)
   ->orientation(90)
   ->sharpen(15)
   ->save();
```

You'll find more examples in [the full documentation](https://docs.spatie.be/image).

Under the hood [Glide](http://glide.thephpleague.com/) by [Jonathan Reinink](https://twitter.com/reinink) is used.

Support us
----------

[](#support-us)

[![](https://camo.githubusercontent.com/11765ae669aeb9a04b86823d47a71ce64ed2f75a461b2764ac107a41e35a339b/68747470733a2f2f6769746875622d6164732e73332e65752d63656e7472616c2d312e616d617a6f6e6177732e636f6d2f696d6167652e6a70673f743d31)](https://spatie.be/github-ad-click/image)

We invest a lot of resources into creating [best in class open source packages](https://spatie.be/open-source). You can support us by [buying one of our paid products](https://spatie.be/open-source/support-us).

We highly appreciate you sending us a postcard from your hometown, mentioning which of our package(s) you are using. You'll find our address on [our contact page](https://spatie.be/about-us). We publish all received postcards on [our virtual postcard wall](https://spatie.be/open-source/postcards).

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

[](#installation)

You can install the package via composer:

```
composer require spatie/image
```

Please note that since version 1.5.3 this package requires exif extension to be enabled:

Usage
-----

[](#usage)

Head over to [the full documentation](https://spatie.be/docs/image).

Changelog
---------

[](#changelog)

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

Testing
-------

[](#testing)

```
composer test
```

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

[](#contributing)

Please see [CONTRIBUTING](https://github.com/spatie/.github/blob/main/CONTRIBUTING.md) for details.

Security
--------

[](#security)

If you've found a bug regarding security please mail  instead of using the issue tracker.

Postcardware
------------

[](#postcardware)

You're free to use this package, but if it makes it to your production environment we highly appreciate you sending us a postcard from your hometown, mentioning which of our package(s) you are using.

Our address is: Spatie, Kruikstraat 22, 2018 Antwerp, Belgium.

We publish all received postcards [on our company website](https://spatie.be/en/opensource/postcards).

Credits
-------

[](#credits)

- [Freek Van der Herten](https://github.com/freekmurze)
- [All Contributors](../../contributors)

Under the hood [Glide](http://glide.thephpleague.com/) by [Jonathan Reinink](https://twitter.com/reinink) is used. We've based our documentation and docblocks on text found in [the Glide documentation](http://glide.thephpleague.com/)

License
-------

[](#license)

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

###  Health Score

25

—

LowBetter than 35% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community19

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

 Bus Factor1

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

Unknown

Total

1

Last Release

1388d ago

### Community

Maintainers

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

---

Top Contributors

[![freekmurze](https://avatars.githubusercontent.com/u/483853?v=4)](https://github.com/freekmurze "freekmurze (169 commits)")[![Nielsvanpach](https://avatars.githubusercontent.com/u/10651054?v=4)](https://github.com/Nielsvanpach "Nielsvanpach (34 commits)")[![sebastiandedeyne](https://avatars.githubusercontent.com/u/1561079?v=4)](https://github.com/sebastiandedeyne "sebastiandedeyne (10 commits)")[![AdrianMrn](https://avatars.githubusercontent.com/u/12762044?v=4)](https://github.com/AdrianMrn "AdrianMrn (9 commits)")[![brendt](https://avatars.githubusercontent.com/u/6905297?v=4)](https://github.com/brendt "brendt (9 commits)")[![Synchro](https://avatars.githubusercontent.com/u/81561?v=4)](https://github.com/Synchro "Synchro (8 commits)")[![nlemoine](https://avatars.githubusercontent.com/u/2526939?v=4)](https://github.com/nlemoine "nlemoine (6 commits)")[![riasvdv](https://avatars.githubusercontent.com/u/3626559?v=4)](https://github.com/riasvdv "riasvdv (4 commits)")[![AlexVanderbist](https://avatars.githubusercontent.com/u/6287961?v=4)](https://github.com/AlexVanderbist "AlexVanderbist (4 commits)")[![akoepcke](https://avatars.githubusercontent.com/u/5311185?v=4)](https://github.com/akoepcke "akoepcke (3 commits)")[![pascalbaljet](https://avatars.githubusercontent.com/u/8403149?v=4)](https://github.com/pascalbaljet "pascalbaljet (3 commits)")[![emielmolenaar](https://avatars.githubusercontent.com/u/2470795?v=4)](https://github.com/emielmolenaar "emielmolenaar (2 commits)")[![armezit](https://avatars.githubusercontent.com/u/2006991?v=4)](https://github.com/armezit "armezit (2 commits)")[![PaolaRuby](https://avatars.githubusercontent.com/u/79208489?v=4)](https://github.com/PaolaRuby "PaolaRuby (1 commits)")[![pculka](https://avatars.githubusercontent.com/u/4672645?v=4)](https://github.com/pculka "pculka (1 commits)")[![pdewit](https://avatars.githubusercontent.com/u/488574?v=4)](https://github.com/pdewit "pdewit (1 commits)")[![rubenvanassche](https://avatars.githubusercontent.com/u/619804?v=4)](https://github.com/rubenvanassche "rubenvanassche (1 commits)")[![sebastianpopp](https://avatars.githubusercontent.com/u/2521500?v=4)](https://github.com/sebastianpopp "sebastianpopp (1 commits)")[![spyrosk](https://avatars.githubusercontent.com/u/4689584?v=4)](https://github.com/spyrosk "spyrosk (1 commits)")[![Trigur](https://avatars.githubusercontent.com/u/26181595?v=4)](https://github.com/Trigur "Trigur (1 commits)")

---

Tags

spatieimage

###  Code Quality

TestsPHPUnit

Static AnalysisPsalm

Type Coverage Yes

### Embed Badge

![Health badge](/badges/armezit-spatie-image/health.svg)

```
[![Health](https://phpackages.com/badges/armezit-spatie-image/health.svg)](https://phpackages.com/packages/armezit-spatie-image)
```

###  Alternatives

[spatie/image

Manipulate images with an expressive API

1.4k60.7M187](/packages/spatie-image)[spatie/browsershot

Convert a webpage to an image or pdf using headless Chrome

5.2k36.7M153](/packages/spatie-browsershot)[spatie/image-optimizer

Easily optimize images using PHP

2.9k79.5M153](/packages/spatie-image-optimizer)[spatie/laravel-health

Monitor the health of a Laravel application

87512.0M161](/packages/spatie-laravel-health)[pimcore/pimcore

Content &amp; Product Management Framework (CMS/PIM/E-Commerce)

3.8k3.8M505](/packages/pimcore-pimcore)[matomo/matomo

Matomo is the leading Free/Libre open analytics platform

21.7k38.9k](/packages/matomo-matomo)

PHPackages © 2026

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