A missing piece for PHP CI/CD
When GitHub Actions launched, early adopters quickly published setup actions for mainstream languages. PHP developers, however, found themselves without an equivalent. Shivam Mathur, a university computer science student who had picked up PHP and JavaScript alongside early lessons in server configuration and deployment automation, decided to fill that gap.
The result is Setup-PHP, a GitHub Action that prepares a complete PHP environment for CI/CD workflows. It handles multiple PHP versions, installs required extensions, popular CLI tools from the PHP ecosystem, and code-coverage drivers—all behind a concise YAML interface.
It can setup various versions of PHP, along with required extensions, various popular CLI tools used by projects in PHP community, code-coverage drivers and a lot more.

The action has since become one of the most-used Actions on the platform, adopted by major PHP projects including PHPUnit, Composer, Symfony, and Laravel, alongside thousands of others in the community.
Starting with a personal problem
Mathur didn't set out to build a flagship Marketplace action. His motivation was practical: he built Setup-PHP initially for his own use and for clients, aiming to reduce repetitive work when configuring testing and delivery pipelines.
Initially I had built it for personal use and for some of my clients, so I can recommend GitHub Actions to them and save myself repeated work while setting up testing and delivery pipelines. When I shared this with the PHP community, it took off. I had many requests for implementing features and improving it so that it can compete with other CI/CD services in terms of ease of use for PHP projects.
That pattern—solving an immediate, personal workflow problem and then discovering broad demand—recurs across many of the most successful Actions. The original inspiration came from GitHub's Setup-Python Action, which Mathur had used previously and wanted to replicate for PHP.
Cross-platform hurdles
Setup-PHP already runs on Linux, Ubuntu, and macOS, and Mathur's roadmap includes broader support for additional Linux distributions and self-hosted runners. Expanding that coverage isn't straightforward, because PHP lacks a unified installation mechanism across operating systems.
PHP – unlike some other languages – does not have a unified way of installing things. Each platform has different ways of setting things up and unifying them in a 6-line YAML interface was a good challenge.
The experience has also been an education in maintaining an open source project at scale. Mathur now aims to turn Setup-PHP into a sustainable long-term project rather than a popular but unmaintained utility.

For anyone considering building their own Action, the takeaway from Mathur's story is straightforward: look for ways to make your own life easier. The tools that address real friction in your workflow are often the ones that resonate most widely with other developers.
Setup-PHP is free and available on the GitHub Marketplace.



