logoalt Hacker News

zsoltkacsandi • today at 10:04 AM • 11 replies • view on HN

I know there were many "PHP is dead" posts in the past, but I think PHP now is really is declining.

I started my career as a PHP developer, it was a popular language especially in web development and at web agencies, and the main reason was that it was relatively cheap to employ PHP devs.

Now with LLMs it is similarly cheap (if not cheaper) to write code in Go, Rust, or any performant languages that are much more sophisticated than PHP and have many other benefits. I don't see any reason anymore to start any new project in PHP.

Other than that this "borrow every single feature from other languages and add it to PHP" strategy is not really a good direction IMO.


Replies

downsplat • today at 1:32 PM

It has some historical warts but it's still a perfectly decent language with lots of modern features too. I quite like the semi-typed style, strong types for function arguments and returns, and duck typed within. Keeps things concise and well-checked enough. I just finished porting a 120kLoC project into php, and I'm quite happy with it. Using Slim as a micro framework, with a custom layer on top.

ExtremelyFat • today at 10:25 AM

None of those languages allow me to edit files directly via (S)FTP and see the changes go live within 2 seconds.

➕ show 5 replies
cutler • today at 11:09 AM

Until another language reproduces the whole WordPress, Drupal, Magento, Moodle etc ecosystems PHP isn't going away.

➕ show 1 reply
ulimn • today at 10:20 AM

I see where you're coming from and I agree to some extent, but having a language (or standard library) rich in features also means we don't have to rely on third party solutions that much. I think this is a pretty good thing/approach - as long as it's well tested of course.

Shish2k • today at 10:36 AM

I've been maintaining (/suffering) a PHP project for ~25 years, which started with PHP because it was the most universally deployable runtime available on bargain-basement web hosts, where a novice user can upload a file over FTP and immediately have a running webapp. Has any other language even attempted to fill that niche yet? D:

(Has the world bifurcated into "point & click configuration of proprietary web hosting like squarespace" for simple sites and "full kubernetes deployments" for more technical things, and nobody cares about entry-level deployment any more?)

➕ show 1 reply
rowanseymour • today at 1:55 PM

You're getting downvoted to oblivion but honestly I agree, I think the only reason anyone has for starting a new project in PHP in 2026 is familiarity. You cannot claim to be picking the best language for the job.

ahofmann • today at 10:21 AM

What is a better direction in your opinion?

shevy-java • today at 10:24 AM

I agree with you for the most part; I think PHP went into decline several years ago already.

TIOBE, while useless, has a trend (there it is somewhat useful; still overall useless, but not 100% useless):

https://www.tiobe.com/tiobe-index/php/

It shows two big hits, one in 2010, one in 2014. I myself switched to ruby in 2005. Ruby is now in a similar situation too. PHP is at rank #12, so that is still decent. I think it is declining only slowly though.

> Now with LLMs it is similarly cheap (if not cheaper) to write code in Go, Rust, or any performant languages that are much more sophisticated than PHP and have many other benefits. I don't see any reason anymore to start any new project in PHP.

Well, the problem with LLMs is that these users will become dependent on e. g. Anthropic, and Anthropic already showed it will censor at will, e. g. "you are not allowed to 3d print anything that looks like a gun" agenda.

I do not think LLMs are what killed PHP or will kill it. The language is simply poorly designed. Not all projects will become LLM though, this is the part I disagree with you. For instance wikipedia will not suddenly be rewritten in LLM-Rust.

stevelacey • today at 1:34 PM

[dead]

trippsydrippsy • today at 11:07 AM

[dead]

abujazar • today at 10:49 AM

Obviously Go and Rust are more modern and performant languages, but they simply can't compete with the versatility of PHP and its ecosystem for a lot of use cases. Many web applications need a large part of the built-in functionality of PHP and one of its frameworks (Laravel or Symfony) in a tightly integrated application. Implementing one part at a time in Go or Rust is a viable option now for some, but far from all use cases. Time is better spent using that same LLM to use Laravel to its fullest.

Your career having moved on from CMS stuff in PHP is not really a good measure for what people actually need : )

➕ show 1 reply