This article was published 9 years ago, therefore the contents of this post may be out of date.

Since PHP first appeared around 20 years it’s been making a lot of buzz for being an effective server-side programming language for web development and as PHP has many uses which makes it a popular language amongst developers to learn and large-scale companies to have PHP developers are always in high demand.

and as PHP is used on a lot of web hosting services and as mod_php is one of the most popular Apache HTTP Server modules. Some popular content management systems (CMS) written in PHP like my favourite WordPress but also Drupal, Joomla etc…..

PHP libraries perform a wide useful function of extending the core functionality of the language. A library is a vast collection of useful resources such as configuration data, pre-written codes, classes, message, values, templates and more.

There are a bunch of PHP libraries that can execute development with greater speed and efficiency. So for today’s round up you will find 12 of the greatest PHP libraries that can help developers in their projects.

1. Whoops


Whoops is a nice PHP library for dealing with errors and exceptions. It supports various PHP frameworks such like Zend and Silex. It offers a functionality to retrieve information about frame context, file and line number as well as add comments to a frame.

2. phpFastCache


phpFastCache is an open source PHP caching library that comes as asingle-file and can be integrated so quickly. It has support for multiple caching methods (apc, memcache, memcached, wincache, files, pdo and mpdo), the period of caching can be defined and has a very simplified API.

3. Parody


Parody is an extremely simple library that can be used to mimic classes and objects as well as provide working results for method calls (both object and static), getting properties, instantiating objects, etc. It uses sequential method chaining to make defining class structures and operation extremely quick.

4. Unirest for PHP


Unirest is a pack of lightweight HTTP libraries for many languages (PHP, Ruby, Python, Java And Objective-C). It has support for GET, POST, PUT, UPDATE, DELETE operations and its methods + response structure are the same in all languages.

5. Stash


Stash makes it easy to speed up your code by caching the results of expensive functions or code. Certain actions, like database queries or calls to external APIs, take a lot of time to run but tend to have the same results over short periods of time. This makes it much more efficient to store the results and call them back up later.



The PHP-CPP library is a C++ library for developing PHP extensions. It offers a collection of well documented and easy-to-use classes that can be used and extended to build native extensions for PHP. This C++ library makes building PHP extensions fun.

7. Hoa


Hoa is a modular, extensible and structured set of PHP libraries. Moreover, Hoa aims at being a bridge between industrial and research worlds. This library is the foundation —the core— of all libraries of Hoa. It proposes fundamentals algorithms, paradigms and mechanisms and many more.

8. Geocoder


Geocoder is a PHP library for building geo-aware applications. It provides a powerful abstraction layer for geo-coding manipulations. Geocoder offers a lot of address-based providers, such as Bing Maps, Google Maps, MapQuest, TomTom and Yandex.

9. Ratchet


Ratchet is a robust PHP library that allows developers to create real time, bi-directional applications between clients and servers over web sockets. It contains useful components, such as Wamp server, Io server, session provider, router, HTTP server, origin check and more.

10. Alice


Alice allows you to create a ton of fixtures/fake data for use while developing or testing your project. It gives you a few essential tools to make it very easy to generate complex data with constraints in a readable and easy to edit way, so that everyone on your team can tweak the fixtures if needed.

11. PHP-PasswordLib


PHP-PasswordLib aims to be an all-inclusive cryptographic library for all cryptographic needs. It is meant to be easy to install and use, yet extensible and powerful enough for even the most experienced developer.

12. Imagine


Imagine is an object-oriented PHP library for working with images and manipulating them. The library can handle frequently-used operations like resize, crop or applying filters. A color class helps generating the RGB values of any given color and methods exist for drawing shapes like arc, ellipse, line, pieSlice and more.


12 Great PHP Libraries for Developers