Skip to content
PHP Exif Library - library for reading and writing Exif headers in JPEG and TIFF files using PHP.
Branch: master
Clone or download
artemShelest and weberhofer XP tags fixed (#115)
* XP tags strings with correct encoding
* Fixed test
* Fixed assignment from exif data
Latest commit d4ca1d5 Feb 16, 2018
Type Name Latest commit message Commit time
Failed to load latest commit information.
examples Convert to new array syntax (PHP 5.4) (#120) Dec 15, 2017
po Remove whitespace [ WhitespaceBot] Dec 16, 2011
scripts Convert to new array syntax (PHP 5.4) (#120) Dec 15, 2017
src XP tags fixed (#115) Feb 16, 2018
test XP tags fixed (#115) Feb 16, 2018
tutorials/PEL Remove whitespace [ WhitespaceBot] Dec 16, 2011
.gitignore Updated dependencies for composer and added composer.lock (#86) Feb 2, 2017
.scrutinizer.yml Enabled code rating (#106) Nov 5, 2017
.travis.yml Clean up the code and all the tests to match coding standards (#121) Dec 17, 2017
AUTHORS Switch from simpletest to PHPUnit Apr 8, 2016 Updated docs to be in Markdown Apr 8, 2016
COPYING Updated with current address of FSF. Oct 1, 2005 Now available from PEL organization (#97) Nov 4, 2017
README.markdown Fix README badges for Packagist (#108) Nov 8, 2017
TODO Fixed read-write unit tests. It tests the DATE_TIME tags and Jan 8, 2006
autoload.php Fixed issues pointed out by Insight by SensioLabs Apr 21, 2016
composer.json Clean up the code and all the tests to match coding standards (#121) Dec 17, 2017 Small changes Dec 5, 2010
makepackagexml.php Convert to new array syntax (PHP 5.4) (#120) Dec 15, 2017
phpcs.xml Refactor ReadWriteTest and fix NumberTest (#122) Dec 18, 2017
phpunit.xml XP tags fixed (#115) Feb 16, 2018 Remove whitespace [ WhitespaceBot] Dec 16, 2011 Remove whitespace [ WhitespaceBot] Dec 16, 2011 Fixed capitalization of Exif to follow the standard. Oct 3, 2005


PEL: PHP Exif Library

Build Status Code Coverage Scrutinizer Code Quality Latest Stable Version Total Downloads License

README file for PEL: PHP Exif Library. A library with support for reading and writing Exif headers in JPEG and TIFF images using PHP.

Copyright (C) 2004, 2005, 2006 Martin Geisler. Licensed under the GNU GPL, see COPYING for details.


The PHP Exif Library (PEL) makes it easy to develop programs that will read and write the Exif metadata headers found in JPEG and TIFF images. See the file INSTALL for an introduction to how PEL can be used by your application.

PEL is a library written entirely in PHP 5, which means that it does not have any dependencies outside the core of PHP, it does not even use the Exif module available for PHP.

Please note that the API for PEL is not yet frozen, and it will remain changeable until version 1.0 is reached. Read the NEWS file for important information about API changes.

Also, please go to the PEL development mailing list (look below) and share your ideas about how the API should look like.


composer require lsolesen/pel

Documentation Overview

  • README.markdown: gives you a short introduction to PEL (this file).
  • explain how to install and get going with PEL.
  • contains important information about changes in PEL.
  • examples/: small self-contained examples of how to use PEL.
  • AUTHORS: list of people who have helped.
  • run to generate API-documention or see it online at

Features of PEL

  • Reads and writes Exif metadata from both JPEG and TIFF images.
  • Supports reading and writing all Exif tags.
  • Supports internationalization.
  • Extensible object-oriented design.
  • PhpUnit tested
  • Documented with PhpDocumentor (

Helping out

Help will be very much appreciated. You can report issues, run the test suite, add patches. The best way to help out is applying patches and helping out with the tests. See instructions in the test/ directory.

All changes to code should be issued through a pull request, and other maintainers should review the code and merge it.


To work with the translations, you need the gettext package installed.

Getting Support

The first place you should consult for support is the documentation supplied with PEL, found in the doc/ directory. There you will find a complete API documentation with descriptions of all classes and files in PEL.

The scripts found in the examples/ directory are also a good source of information, especially the edit-description.php file which has tons of comments.

PEL is hosted on Github and uses the tools found there for support. This means that all questions, bug reports, etc. should be directed there (and not directly to the developers).

Please try the latest version before reporting bugs -- it might have been fixed already. The latest code can be found in the git repository at

It is very helpful if you try out the latest code from the git repository before submitting a bug report. The code found there is generally very stable.

Contributing Test Images

To make PEL as stable as possible, it is tested with images from a number of different camera models.

New test images are very much appreciated -- please download the existing test images and read the README file found there for instructions.


Please see the AUTHORS file for a list of people who have contributed to PEL. See the full list of code contributors.

You can’t perform that action at this time.