PHP at 30: A Resilient Journey, Modern Features, and a Go-Powered Future
PHP turns 30, evolving from a widely criticized web language into a modern powerhouse. This article explores its journey, parallels with JavaScript, and a Go-powered future via FrankenPHP.
In 1995, an otherwise unknown software developer released the first version of a new scripting language, explicitly aiming to create applications for the nascent "World Wide Web" platform. Starting as a small project, and boosted by the frenetic dot-com years, it dramatically grew into one of the most widely used programming languages of all time. After some initial stumbles, it achieved a form of standardization in 1997, even reluctantly incorporating some OOP features to satisfy both the community and pundits.
However, despite its efforts, this language and its users were mocked for decades by so-called "serious" programmers. They derided its "WTF"-level syntax, the quirks of its runtime model, its ever-increasing security issues, and the countless frameworks that emerged around it. Despite the backlash, the language and its community persevered, eventually experiencing a significant revival, even gaining explicit support from Big Tech itself. Today, as the language approaches its glorious 30th year, a new project, leveraging the strengths of the Go programming language, is driving its future evolution.
Interestingly, the description across these two paragraphs fits not one, but two programming languages. On one side, PHP, heavily inspired by Perl and released by Rasmus Lerdorf in June 1995 under the name "Personal Home Page Tools." On the other hand, JavaScript, designed by Brendan Eich and released in December of that same year by Netscape.
The parallels between these languages extend further. In 1997, both achieved some level of standardization, thanks to PHP/FI 2 and ECMA-262. During the 2010s, each language received major support: Facebook for PHP, and Google and Microsoft for JavaScript. And in 2025, both are undergoing significant revamp efforts based on the Go programming language: a new PHP runtime called FrankenPHP, and the recently announced TypeScript compiler.
PHP and JavaScript represent two sides of the same coin: web programming, both server-side and client-side. The growth of the World Wide Web transformed them into major players, despite their (let's be honest) quite jarring initial design flaws, their slow, committee-based evolution, and the seemingly endless series of security vulnerabilities that plagued their respective ecosystems.
Bjarne Stroustrup, the creator of C++, famously smirked, "There are only two kinds of languages: the ones people complain about and the ones nobody uses." Two years ago, we published an issue about BASIC, the programming language that all developers love to hate but which single-handedly defined a whole era in our industry. It's only fair that we dedicate some words to PHP, another language everyone complains and laughs about, yet it apparently powers between 70 and 80 percent of the world’s websites – an impressive number, no matter how you look at it or how much "serious" programmers scoff.
Throughout history, programming languages have received interesting, if revealing, epithets. C is called “portable assembly.” Java is known for “write once, debug anywhere.” Python is usually referred to as “executable pseudocode.” JavaScript "was created in 10 days, and it shows." Perl is the “duct tape of the Internet.” And, well, PHP is either a "fractal of bad design" (seriously, people?) or an acronym meaning "Pretty Horrific Programming." Ouch.
Here's how I see things: PHP is the lingua franca of affordable cloud web hosting options; or, in other terms, the Toyota Corolla of programming languages: boring, solid, easy, and affordable. You can find, almost anywhere in the world, an affordable web hosting option offering the holy quadrinity of LAMP: Linux, Apache, MySQL, and PHP; an operating system, a web server, a database server, and a scripting language, all in an inexpensive package, enabling the masses to go further. Paraphrasing George Clooney, what else?
These days, PHP features many traits of a modern programming language. Let's enumerate some, beginning with its fully open-source nature. It has advanced OOP features like traits, property hooks, namespaces, attributes, and enums. It includes functional programming constructs, like closures with capture lists and arrow functions, and a "pipe" operator coming next November (rejoice, OCaml and F# developers!). PHP has associative arrays and a rudimentary yet fast, useful, and growing type checking system (remember: declare(strict_types=1); is your friend) including never and nullable types. It bundles a full library of algorithms ready to use, following the "batteries included" mantra, and if all else fails, there's a powerful and open-source package manager with enough packages to make npm blush. There's excellent support for unit testing. As scripting programming languages go, it's quite fast to compile and execute. It has its own ecosystem of conferences, a mascot, and even a powerful IDE made by none other than JetBrains.
But, alas, it does feature a goto operator. Oh, là, là! What would Dijkstra say! Not to mention those pesky variables prefixed with a stupid dollar sign, and a cringeworthy foreach statement. The ignominy!
Most so-called "serious" programmers would be wise to step down from their ivory tower and take a look at PHP in 2025 before an LLM kicks them out of their job. The language has seen major, steady, and consistent revamps for the past decade, including a stable release rhythm once per year, every November, plus a dedicated team that has been consistently removing security vulnerabilities and replacing obsolete APIs with newer and safer ones.
I know they should take another look at PHP because I myself had to step down from my own ivory tower and do that. It's only fair to state my mea culpa: back in 2009, I participated in an (admittedly useless) community effort called "I Hate PHP" (of which the Internet Archive has duly kept a copy) where my name appeared prominently on the front page. I plead guilty, your honor.
In my defense, I will argue that those were the somewhat darker ages of PHP. Those were the times of Bruce Tate’s “Beyond Java” and its long diatribes against PHP spread throughout its pages. Remember the long-gone PHP Security Consortium? Are the days of Little Bobby Tables over? Let's be honest; not really. You can still release code with SQL injection vulnerabilities if you want (hint: avoid the . operator as much as you can. For all things that are not database queries, string interpolation is your friend).
The Rt. Rvd. Pastor Manul Laphroaig, in his sermon to the Beloved Congregation of the First United Church of the Weird Machines, claimed that there is divinity in every programming language… including PHP: "If a language like PHP introduces so many people to pwnage, then that is its divinity. It provides a first step for children to learn how program execution goes astray, with control and data so easy to mangle." Amen.
Nowadays, what I see is a healthy, thriving community around PHP. One that, with the exception of JetBrains, is not encumbered by the whims of a FAANG or any other “Big Tech” firm. And the PHP Foundation is driving the evolution of its standards towards the future, hopefully navigating that unstable space between money and people.
Take these numbers with a grain of salt, but if we look at language ratings, there's a lot of terrain to reclaim: on TIOBE, even if PHP was named language of the year 2004, it presently appears at the 15th position and going down (it used to be 3rd in 2010). In the IEEE ranking, it appears in the 13th position, and on the 7th position at PYPL, which is quite a drop in the past 20 years. But hey! It appears 4th at the RedMonk ranking, and the graph shows that the fall from 2013 to now has not been that strong. Not all is lost!
Jokes aside, the most important developments in the history of PHP had to do with the engines used to power it. For decades, the Zend engine served as the reference point for the evolution of the language. Designed for the needs of the World Wide Web of 1999 (a world of LAMP stacks) and as good as it was for its time, it could not evolve gracefully into a world of DevOps, containers, and Kubernetes orchestrators. (Raise your hand if you have ever tried to put together a Dockerfile with Nginx, FPM, and Supervisor, to run some forgotten PHP 7.1 application. I feel your pain, my friend.)
Thankfully, we can move away from Zend now. Thanks to the unpredictable power of its community, there is this thing called FrankenPHP. This project has been recently adopted by the PHP Foundation as an official runtime, and it ticks all the boxes that could propel PHP into another orbit.
FrankenPHP not only dramatically simplifies the creation of containers but also provides new execution models for PHP code, all while offering 100% compatibility with the massive existing codebase. We talk more about FrankenPHP in the Vidéothèque section this month.
As nice as FrankenPHP is, I do not count on the end of the backlash against PHP anytime soon. The language will continue to suffer the stigma of its humble beginnings. Rasmus Lerdorf did not get an interview in “Masterminds of Programming” because PHP is the quintessential language built in a bazaar, as the fruit of an accidental affair design. Nor will Rasmus be invited to the next HOPL conference, despite the unreasonable popularity of the language, nor will PHP be used for PhD dissertations (other than those related to security, that is). To add insult to injury, PHP is not even mentioned in the “Tao of Programming” (OK, OK, it was published in 1987, I give you that).
But thankfully, IEEE’s “Computer Magazine” did pay attention to PHP and followed suit with an interview of Rasmus in both written and video formats, published in 2012. At least that. In that interview, Rasmus states the core philosophy behind the bazaar: “I learned a bit along the way that, for this to grow, I had to give up control of PHP—I had to let other people have some control. (...) It’s not just them contributing to my project—it becomes our project, and that really changed the nature of PHP.”
Cover photo by KOBU Agency on Unsplash.