Get your next remote job on LaraJobs.

The best PHP packages to use in 2024

The best PHP packages to use in 2024


As a developer in the ever-evolving landscape of PHP, I’ve found myself relying directly or indirectly on a handful of remarkable packages that have significantly improved my coding efficiency and product quality. Let me share some of these gems with you.

The best PHP packages to use

Monolog - Versatile logging for PHP

Monolog’s official website

Monolog is a must-have. It’s incredibly flexible, allowing you to send logs to various outputs like files, sockets, and databases. Its compatibility with the PSR-3 interface makes it a versatile choice for integrating logging into any PHP project. Whether you’re managing error logs or system health data, Monolog will do its job well. It’s such a great package that Laravel has adopted it as their default logging library.

Carbon - Date and time the easy way

Carbon’s official website.

Handling date and time in PHP is something we all have to do. And Carbon makes it even easier. It extends PHP’s DateTime class and offers a plethora of functionalities that simplify date-time management. What I appreciate the most is its human-readable syntax, making time manipulations and calculations a breeze.

Flysystem - File storage made simple

Flysystem’s official website.

Flysystem is a file storage library that abstracts different file system types. Be it local storage or cloud storage like AWS S3, Flysystem provides a unified API to manage them all. This package has saved me from the hassle of handling storage differences when deploying across various environments. This package has also been adopted by Laravel.

Faker - The master of fake data

Faker’s official website.

When it comes to testing or seeding databases with dummy data, Faker is my go-to package. It’s incredibly easy to generate any type of fake data, from names and addresses to lorem ipsum text. It supports multiple languages too, which is handy for localization testing. I personally don’t know what I’d do without it.

league/commonmark - A Markdown parser

league/commonmark’s official website

Need to parse Markdown? The league/commonmark package is a highly-efficient Markdown parser for PHP. It adheres to the CommonMark specification and is extendable, allowing you to add custom features. It’s used by Laravel by default and therefore, the one I use on this blog. league/commonmark’s code is well put together, making it hard to understand and extend. But when you finally get it, it’s extremely powerful.

Be the first to comment!

Get help or share something of value with other readers!

Great deals for enterprise developers
The latest community links

Recommended articles

How does Laravel work? A crystal clear explanation.

Discover my step by step and simple explanation of how Laravel makes your life easier.

20+ Laravel best practices, tips and tricks to use in 2024

Learning a framework can be overwhelming, but time and execution will make you a master. Here are some best practices to help you toward your goal.

Laravel interview questions and answers for 2024

Nailing a Laravel job interview can be a daunting task, but with the right preparation and mindset, you can set yourself up for success.

9 testing best practices for Laravel in 2024

Are you familiar with testing? Good. Here are a bunch of best practices to help you level up even more!

The best PHP blogs to read in 2024

To keep getting better with PHP, you should subscribe to as many quality blogs as possible. In this article, I share the ones I often read myself.

12 Laravel security best practices for 2024

Secure your Laravel app: protect sensitive files, keep your packages and Laravel updated, use policies, validate input, and more.

Laravel 10 is out! Here are every new features and changes.

Laravel 10 has been released on February 14, 2023. Let's dive into every relevant new features and changes.

The 6 best PHP cloud hosting providers for 2024

Make an informed decision for your PHP applications thanks to my list of the best cloud hosting providers.

- / -