This article is reposted from: http://www.scutephp.com/topic-id1325.html A collection of commonly used PHP libraries, resources and tips, so you can quickly find what you need at work… 
Learning Resources
Valuable php-related resources for reference: communities, blogs, websites, articles, books, videos and so on
- PHP Websites
- PHP The Right Way A quick reference guide to PHP practices
- PHP Books
- Modern PHP - by the founder of PHP The Right Way and the author of the Slim framework
Dependency Management
Packages and frameworks for dependency management
- Composer / Packagist - A package and dependency manager.
- Composer Installers - A multi-framework Composer library installer
- pickle - A PHP extension installer
- Melody - A tool to build one file Composer scripts.
Frameworks
Web development frameworks
- Symfony2 - A framework built from standalone components (SP2)
- Zend Framework 2 - Also a framework built from standalone components (ZF2)
- Laravel 5 - A concise and elegant PHP web development framework (L5)
- Aura PHP - A framework of standalone components
- Yii2 - A high-performance PHP framework for developing large-scale web applications
- Nette - Also a framework built from standalone components
- PPI Framework 2 - An interactive framework
- CakePHP - An efficient application development framework (CP)
- Phalcon - A framework that works as a C extension
- Yaf - A C-extension framework by Laruence
Components
- Aura Components - A PHP 5.4 component package
- Hoa Project - A collection of PHP components
Micro Frameworks
Micro frameworks and routing
- Silex - A micro framework built on Symfony2 components
- Silex Skeleton - A project skeleton for Silex
- Silex Web Profiler - A web debug toolbar for Silex
- Slim - Another simple micro framework
- Slim Skeleton - A skeleton for Slim
- Slim View - A collection of custom views for Slim
- Slim Middleware - A collection of custom middleware for Slim
- SlimMVC-Skeleton - Implements MVC and some components on top of Slim
- Bullet PHP - A micro framework for building REST APIs
- Lumen - A micro framework based on Laravel
- Proton - A micro PHP framework
- blink - A high-performance micro web framework born for building “long running” services
Routers
- Fast Route - An efficient routing library
- Route - A routing library based on Fast Route
- Pux - Another efficient routing library
- Klein - A flexible routing library
- Macaw - A simple PHP router that is super lean, fast and very sexy.
Templating
Libraries and tools for templating and lexing
- Twig - A comprehensive template language
- Twig Cache Extension - A template fragment caching library for Twig
- Mustache - A PHP implementation of the Mustache template language
- Phly Mustache - Another PHP implementation of the Mustache template language
- MtHaml - A PHP implementation of the HAML template language
- PHPTAL - A PHP implementation of the TAL template language
- Plates - A native PHP template library
- Lex - A lightweight template parser
Static Site Generators
Preprocessing tools that generate web page content
- Sculpin - A tool that converts Markdown and Twig into static HTML
- Phrozn - Another tool that converts Textile, Markdown and Twig into HTML
HTTP
Libraries for HTTP and scraping websites
- Guzzle - A full HTTP client
- Buzz - Another HTTP client
- Requests - A simple HTTP library
- HTTPFul - A chainable HTTP client
- Goutte - A simple web scraper
- PHP VCR - A library for recording and replaying HTTP requests
Middlewares
Middleware libraries for building applications
URL
Libraries for parsing URLs
- Purl - A URL manipulation library
- PHP Domain Parser - A local suffix parser
- Uri - A simple URL manipulation library
Libraries for sending and parsing email
- SwiftMailer - A mailer solution
- PHPMailer - Another mailer solution
- Fetch - An IMAP library
- Email Reply Parser - An email reply parser library
- Stampie - A library for email services such as SendGrid, PostMark, MailGun and Mandrill
- CssToInlineStyles - A library for inlining CSS in email templates
- Email Validator - A small email validation library
Files
About file handling and MIME type detection
- Gaufrette - A filesystem abstraction layer
- Flysystem - Another filesystem abstraction layer
- Canal - A library for inspecting internet media types
- Apache MIME Types - A library for parsing Apache MIME types
- Ferret - A MIME detection library
- Hoa Mime - Another MIME detection library
- Lurker - A resource tracking library
- PHP File Locator - A library for locating files in large projects
- PHP FFmpeg - A library that wraps FFmpeg for video
- CSV - A CSV data manipulation library
Stream
Libraries for working with streams
- Streamer - A simple object-oriented stream wrapper library
Dependency Injection
Libraries that implement the dependency injection design pattern
- Pimple - A small dependency injection container
- Auryn - Another small dependency injection container
- Container - Another flexible dependency injection container
- PHP DI - A dependency injection implementation using annotations
- Acclimate - A common interface for dependency injection containers and service locators
- Symfony DI - A dependency injection component (SF2)
Imagery
Libraries for manipulating images
- Imagine - An image processing library
- PHP Image Workshop - Another image processing library
- Intervention Image - Yet another image processing library
- GIF Frame Extractor - A library for extracting frame information from animated GIFs
- GIF Creator - A library for creating animated GIFs from multiple images
- Image With Text - A library for embedding text into images
- Color Extractor - A library for extracting colors from images
- Glide - An on-demand image processing library
- Image Optimizer - A library for optimizing images
- PHPThumb - A thumbnail processing library
Testing
Testing codebases and libraries for generating test data
- PHPUnit - A unit testing framework
- DBUnit - A code testing library for PHPUnit
- ParaTest - A parallel testing library for PHPUnit
- PHPSpec - A unit testing library based on specifications
- Codeception - A full-stack testing framework
- AspectMock - A mocking framework for PHPUnit/Codeception
- Atoum - A simple testing library
- Mockery - A mock object library for testing
- Phake - Another mock object library for testing
- Prophecy - A powerful mocking framework
- Faker - A fake data generation library
- Samsui - Another fake data generation library
- Alice - A library for generating complex data
- Behat - A behavior-driven development (BDD) testing framework
- Pho - Another behavior-driven development testing framework
- Mink - Web acceptance testing
- HTTP Mock - A library for mocking HTTP requests in unit tests
- VFS Stream - A virtual filesystem stream wrapper for testing
- VFS - Another virtual filesystem for testing
- Locust - A modern load testing library written in Python
- Peridot - An event-driven testing framework
Continuous Integration
Libraries and applications for continuous integration
- Travis CI - A continuous integration platform
- SemaphoreCI - A continuous integration platform for open source and private projects
- PHPCI - An open source continuous integration platform for PHP
- Sismo - A continuous testing server library
- Jenkins - A continuous integration platform with PHP support
- JoliCi - A Docker-powered continuous integration client written in PHP
Documentation
Libraries for generating project documentation
- Sami - An API documentation generator
- APIGen - Another API documentation generator
- PHP Documentor 2 - A documentation generator
- phpDox - A documentation generator for PHP projects (not just API docs)
Security
Libraries for generating secure random numbers, encrypting data, scanning for vulnerabilities and tokens
- HTML Purifier - A standards-compliant HTML filter
- RandomLib - A library for generating random numbers and random strings
- True Random - A library that generates random numbers using www.random.org
- SecurityMultiTool - A PHP security library
- PHPSecLib - A pure PHP secure communications library
- TCrypto - A simple key-value encrypted storage library
- PHP IDS - A structured PHP security layer
- PHP SSH - An object-oriented SSH wrapper library
- IniScan - A tool for scanning the security of PHP INI files
- SensioLabs Security Check - A web tool that checks Composer dependencies against security advisories
- Zed - An integrated penetration testing tool for web applications
- php-jwt( JSON Web Token ) - A JSON web token library
- jose - A library for JSON signing and encryption
Passwords
Libraries and tools for handling and storing passwords
- Password Compat - A compatibility library for the new PHP 5.5 password functions
- phpass - A portable password hashing framework
- PHP Password Lib - A library for generating and validating passwords
- Password Policy - A password policy library for PHP and JavaScript
- Password Validator - A library for validating and upgrading password hashes
- Zxcvbn PHP - A PHP password strength estimation library based on Zxcvbn JS
- GenPhrase - A library for generating secure random passphrases
Code Analysis
Tools for analyzing, parsing and manipulating codebases
- PHP Parser - A PHP parser written in PHP
- PHPPHP - A PHP virtual machine implemented in PHP
- PHPSandbox - A sandbox environment for PHP
- Dissect - A collection of lexing and parsing tools
- PHP Mess Detector - A library that scans for code bugs, suboptimal code and unused parameters
- PHP Code Sniffer - A library that detects violations of PHP, CSS and JS coding standards
- PHPCPD - A library that detects copy-paste code
- PHP Analyser - A library that analyzes errors in PHP code
- PHP CS Fixer - A coding standards library
- PHP Manipulator - A library for analyzing and modifying PHP source code
- PHP Metrics - A static measurement library
- PHP Refactoring Browser - A command-line tool for refactoring PHP code
- UBench - A simple, small benchmarking library
- Athletic - An annotation-based benchmarking library
- Mondrian - A code analysis tool using graph theory
- Scrutinizer - A web tool for inspecting PHP code
- PHPLOC - A tool for quickly measuring the size of a PHP project
- PHPCheckstyle - A tool that helps follow specific coding rules
- PhpDependencyAnalysis - A tool for creating customizable dependency graphs
- Code Climate - Automated code review
- PHP Error - Used to convert standard PHP error messages, mainly for debugging during development
Architectural
Libraries about design patterns, programming conventions and code organization
- PHP Option - A PHP option type library
- Ruler - A simple stateless production rule engine
- Finite - A simple PHP finite state machine
- Compose - A function composition library
- Monad PHP - A simple Monad library
- Patchwork - A library for redefining user functions
- Galapagos - Language transformation evolution
- Design Patterns PHP - A library of design pattern examples implemented in PHP
- Functional PHP - A functional programming library
- Lib Accessor - A library that simplifies access
- Iter - A library that provides iteration primitives using generators
Debugging and Profiling
Libraries and tools for debugging code
- xDebug - A PHP debugging and profiling tool
- PHP Debug Bar - A debug toolbar
- PHP Console - A web debugging console
- Barbushin PHP Console - A web debugging control tool that uses Google Chrome
- PHPDBG - An interactive PHP debugger
- Tracy - A simple library for error detection, logging and time measurement
- Z-Ray - A debugging and profiling tool
- xHprof - Facebook’s open source PHP profiling tool
- Blackfire.io - A low-overhead code profiler
- Kint - A debugging and profiling tool
Build Tools
Project build and automation tools
- Go - A simple PHP build tool
- Bob - A simple project automation tool
- Phake - A PHP clone library
- Box - A tool for building PHAR files
- Phing - A PHP project build system based on Apache Ant
Task Runners
Libraries for running tasks automatically
- Task - A pure PHP task runner based on Grunt and Gulp
- Robo - An object-oriented PHP task runner
- Bldr - A PHP task runner built on Symfony components
Navigation
Tools for building navigation structures
- KnpMenu - A menu library
- Cartographer - A sitemap generation library
Asset Management
Tools for managing, compressing and minimizing website assets
- Assetic - An asset management pipeline library
- Pipe - Another asset management pipeline library
- Munee - An asset optimization library
- JShrink - A JavaScript minification library
- Puli - A library for detecting absolute paths of assets
Geolocation
Libraries that encode addresses using latitude and longitude
- GeoCoder - A geocoding library
- GeoTools - A library of geo-related tools
- PHPGeo - A simple geo library
- GeoJSON - An implementation of GeoJSON
Date and Time
Libraries for working with dates and times
- Carbon - A simple date time API extension
- ExpressiveDate - Another date time API extension
- CalendR - A calendar management library
Event
Libraries that implement event-driven or non-blocking event loops
- React - An event-driven, non-blocking I/O library
- Rx.PHP - A reactive extension library
- Ratchet - A web socket library
- Hoa WebSocket - Another web socket library
- Elephant.io - Another web socket library
- Hoa EventSource - An event source library
- Evenement - An event dispatcher library
- Event - Event package for your app and/or domain.
- Cake Event - An event dispatching library
- Broadway - An event sourcing and CQRS library
Logging
Libraries for generating and handling log files
- Monolog - A comprehensive logging library
- KLogger - An easy-to-use PSR-3 logging class
- Analog - A closure-based micro logging package
E-commerce
Libraries and applications for payment and for building online e-commerce stores
- OmniPay - A multi-gateway payment processing framework
- Payum - A payment abstraction library
- Sylius - An open source e-commerce solution
- Thelia - Another open source e-commerce solution
- Money - Fowler’s money pattern implemented in PHP
- Sebastian Money - A library for handling monetary values
- Swap - An exchange rate library
Libraries and software for handling PDF files
- Snappy - A PDF and image generation library
- WKHTMLToPDF - A tool that converts HTML to PDF
- PHPPdf - A library that converts XML into PDF and images
Office
Libraries for handling the various Office suite documents
- PHPWord - A library for handling Word documents
- PHPExcel - A library for handling Excel documents
- PHPPowerPoint - A library for handling PowerPoint slides
- ExcelAnt - A library for manipulating Excel documents
Database
Libraries for interacting with databases using object-relational mapping (ORM) or data mapping techniques
- Doctrine - A complete DBAL and ORM
- Doctrine Extensions - An extension collection of Doctrine behaviors
- Propel - A fast ORM, migration and query library
- Eloquent - The Laravel 5 ORM (L5)
- Baum - A nested set implementation for Eloquent
- Spot2 - An ORM mapper for MySQL
- RedBean - A lightweight, easy-to-configure ORM
- Pomm - An object model manager for PostgreSQL
- ProxyManager - A set of tools for generating proxy objects for data mappers
- Cake ORM - An object-relational mapper that implements the data mapping pattern (CP)
- Medoo - A lightweight ORM that speeds up development
Migrations
Libraries for managing database schemas and migrations
- PHPMig - A migration management library
- Phinx - A database migration management library
- Migrations - Another migration management library
- Doctrine Migrations - A migration library for Doctrine
NoSQL
Libraries for working with NoSQL backends
- MongoQB - A MongoDB query building library
- Monga - A MongoDB abstraction library
- Predis - A feature-complete Redis library
Queue
Libraries for handling event and task queues
- Pheanstalk - A Beanstalkd client library
- PHP AMQP - A pure PHP AMQP library
- Thumper - A RabbitMQ pattern library
- Bernard - A multi-backend abstraction library
- php-resque - A redis-based message queue
- Gearman - A task distribution system
Search
Libraries and software for indexing and querying data
- ElasticSearch PHP - The official client library for ElasticSearch.
- Elastica - Another ElasticSearch client library
- Solarium - A client library for Solr.
- SphinxQL query builder - A query library for the Sphinx search engine
Command Line
Libraries for building command-line tools
- symfony/console - The Symfony command-line component
- Boris - A micro PHP REPL
- PsySH - Another PHP REPL
- Pecan - An event-driven, non-blocking shell
- GetOpt - A command-line option parser
- OptParse - Another command-line option parser
- Commando - A simple command-line option parser
- GetOptionKit - Yet another command-line option parser
- Cron Expression - A library for calculating cron run dates
- ShellWrap - A simple command-line wrapper library
- Hoa Console - Another command-line library
- Shunt - A command-line library for running in parallel on multiple remote machines
- Cilex - A small framework for building command-line tools
- CLImate - A library for outputting colors and special formatting
- Webmozart Console
Authentication and Authorization
Libraries that implement authentication patterns
- Sentinel - An authentication and authorization framework
- Sentinel Social - A library for social network authentication
- Opauth - Provides support for OAuth authentication with a unified, standard access approach
- OAuth2 Server - An OAuth2 authentication server, resource server and client library
- OAuth2 Server - An OAuth2 server implementation
- PHP oAuthLib - Another OAuth library
- TwitterOAuth - A Twitter OAuth library
- TwitterSDK - A fully tested Twitter SDK
- Hawk - A Hawk HTTP authentication library
- HybridAuth - An open source social login library
- Lock - An Access Control Lists (ACL) system library.
- OAuth 1.0 Client - An OAuth 1.0 client library.
- OAuth 2.0 Client - An OAuth 2.0 client library.
- Sentry - An authentication and authorization system
- EvaOAuth - A PHP OAuth login library with a unified interface
Markup
Libraries for handling markup
- Decoda - A lightweight markup parsing library
- PHP Markdown - A Markdown parser
- CommonMark PHP - A Markdown parser supporting the CommonMark spec.
- Parsedown - A Markdown parser
- Ciconia - A Markdown parser with Github-flavored support
- Cebe Markdown - A fast, extensible Markdown parser
- HTML5 PHP - An HTML5 parsing and serialization library
- Emoji - A simple library for handling emoji
Strings
Libraries for parsing and manipulating strings
- ANSI to HTML5 - A library that converts ANSI to HTML5
- Patchwork UTF-8 - A portable library for handling UTF-8 strings
- Hoa String - Another UTF-8 string library
- Stringy - A multibyte-aware string manipulation library
- Color Jizz - A library for manipulating and converting colors
- UUID - A library for generating UUIDs
- Slugify - A library that converts strings into slug format
- Urlify - A PHP port of Django’s URLify.js
- Text - A text processing library
- SQL Formatter - A library for formatting SQL statements
- UA Parser - A library for parsing UA (User Agent) strings
- Device Detector - Another library for parsing UA (User Agent) strings
- Mobile-Detect - A lightweight library for detecting mobile devices (including desktop devices)
- Browser - Detects information about the user’s browser environment
Numbers
Libraries for working with numbers
- Numbers PHP - A library for working with numbers
- Math - A library for working with large numbers
- ByteUnits - A library for parsing, formatting and converting byte units in the binary and measurement systems
- PHP Units of Measure - A library for converting between units of measure
- PHP Conversion - Another library for converting between units of measure
- LibPhoneNumber for PHP - A PHP implementation of Google’s phone number handling system
- hashids.php - Used to generate unique strings from integers (for example, hiding the real id by encrypting and decrypting it)
Filtering ang Validation
Libraries for filtering and validating data
- Filterus - A simple PHP filtering library
- Respect Validation - A simple validation library
- Valitron - Another data validation library
- Cake Validation - Another data validation library
- php-readability - A content analysis algorithm
- Upload - A library for handling file uploads and validation
- DMS Filter - An annotation-based filtering library
- MetaYaml - A schema validation library supporting YAML, JSON and XML
- ISO-codes - A library for validating various ISO and ZIP codes
REST and API
Libraries and web frameworks for developing restful APIs
- Apigility - An API builder built with Zend Framework 2
- Hateoas - A HATEOAS REST web service library
- HAL - A Hypertext Application Language (HAL) building library
- Negotiation - A content negotiation library
- Drest - A library that exposes Doctrine entities as REST resource nodes
- Restler - A lightweight framework that exposes PHP methods as RESTful web APIs
- fractal - [best practice] unified handling of data returned
Caching
Libraries for caching data
- Alternative PHP Cache (APC) - An open source opcode cache for PHP
- Doctrine Cache - A caching library.
- Zend Cache - Another caching library
- Cake Cache - A library for caching
- Stash - Another caching library
- CacheTool - A command-line tool for clearing the APC/opcode cache
- PhpFastCache - A PHP caching library
Data Structure and Storage
Libraries that implement data structures and storage techniques
- Ardent - A data structure library
- PHP Collections - A simple collection library
- Serializer - A library for serializing and deserializing data
- Zend Serializer - Another library for serializing and deserializing data
- PHP Object Storage - A library for object storage
- Fractal - A library that converts complex data structures into JSON output
- Totem - A library for managing and creating data change sets
- PINQ - A real-time Linq library for PHP
- JsonMapper - A library that maps embedded JSON structures onto PHP classes
- Cake Collection - A simple collection library
Notifications
Libraries about notifications
- Nod - A notification library
- Notificato - A library for handling push messages
- Notification Pusher - A standalone library for device push notifications
- Notificator - A lightweight notification library
Deployment
Libraries for project deployment
- Pomander - A deployment tool for PHP applications
- Rocketeer - A fast and simple deployer for PHP
- Envoy - A tool for running SSH tasks using PHP
- Plum - A deployment library
- Deployer - A deployment tool
Internationalisation and Localisation
Libraries for internationalization (I18n) and localization (L10n)
Third Party APIs
Libraries for accessing third-party APIs
Extensions
Libraries that help build PHP extensions
- Zephir - A compiled language between PHP and C++ for developing PHP extensions
- PHP CPP - A C++ library for developing PHP extensions
Miscellaneous
Useful libraries and tools that don’t fit the categories above
- pinyin - A library that converts Chinese characters to pinyin
- Pinyin - A library that converts Chinese characters to pinyin
- class.upload.php - A file upload handling class
- php-paginator - A pagination handling class
- Underscore.php - A PHP implementation of Underscore.js
- Flexihash - A consistent hashing library
- Eden - A rapid PHP development library that includes many components for autoloading, event driving, documentation systems, caching, templating, internationalization, databases, web services, payment gateways, loading and cloud service technologies.
- html-parser - An HTML parsing tool
- PHPCrawl - A PHP crawler framework

