PHPackages                             ministryofweb/image-fix-exif-orientation - 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. ministryofweb/image-fix-exif-orientation

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

ministryofweb/image-fix-exif-orientation
========================================

Automatically rotates an image based on its orientation stored in Exif data. Supports GD and ImageMagick/IMagick.

1.0.0(5y ago)12.4k↓47.1%MITPHPPHP ^7.3 || ^8.0CI failing

Since Nov 15Pushed 5y ago1 watchersCompare

[ Source](https://github.com/ministryofweb/image-fix-exif-orientation)[ Packagist](https://packagist.org/packages/ministryofweb/image-fix-exif-orientation)[ RSS](/packages/ministryofweb-image-fix-exif-orientation/feed)WikiDiscussions main Synced today

READMEChangelogDependencies (4)Versions (5)Used By (0)

Automatically Fix Image Orientation
===================================

[](#automatically-fix-image-orientation)

This library automatically rotates an image based on its orientation stored in Exif data. Supports GD and ImageMagick/IMagick.

Requirements
------------

[](#requirements)

- PHP 7.3+ compiled with `--enable-exif`
- at least one of the GD or IMagick extensions

License
-------

[](#license)

This library is licensed under the MIT License.

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

[](#installation)

```
composer require mjaschen/image-fix-exif-orientation
```

Usage
-----

[](#usage)

The following example is also located in the `examples` sub-directory and can directly be run from there.

```
