"PHP is Dead": The Annual Myth vs. the Reality of the Numbers
Every year, someone announces the end of PHP. Yet, production statistics, PHP 8 performance, and Laravel's maturity tell a completely different story.
Bendy SERVILUS3 min read8 views
Every year, the same ritual returns to social media: someone publishes a post announcing that "PHP is dead". And every year, while the debate entertains the crowd, millions of servers quietly continue to answer billions of requests in PHP.
I work daily with Next.js / TypeScript, Python, and Laravel. For me, choosing a tool shouldn't be based on hype, but on facts. So, what do the numbers actually say?
1. Production Statistics
The gap between what we read online and the reality of the web is striking. According to W3Techs, which continuously analyzes web technologies:
69% of websites whose server-side language is known use PHP.
Over 40% of all websites run on WordPress, written in PHP.
Among PHP websites, 65% are already using PHP 8.
This last figure matters just as much as the first. It shows that PHP is not just present: it is maintained and updated.
2. PHP 5 vs PHP 8: Two Different Languages
Why this persistent reputation? Because many critics still target the PHP of the 2000s and 2010s: unpredictable typing, HTML mixed with SQL in the same file, lack of standards.
Modern PHP has very little to do with this legacy:
Performance: PHP 7 roughly doubled execution speed compared to PHP 5.6. PHP 8 then added a JIT compiler, mostly useful for heavy computations.
Type System: union types, native enumerations (
enum),readonlyclasses, and property hooks since PHP 8.4.Static Analysis: tools like PHPStan or Psalm detect type errors before runtime, much like the TypeScript compiler.
Here is what professional PHP looks like today:
<?php
declare(strict_types=1);
namespace App\Services\Payment;
use App\Contracts\FraudScorerInterface;
use App\DTO\TransferPayload;
use App\Enums\TransactionStatus;
final readonly class MobileMoneyVerifier
{
public function __construct(
private FraudScorerInterface $scorer,
private float $riskThreshold = 0.85,
) {}
public function evaluate(TransferPayload $payload): TransactionStatus
{
$score = $this->scorer->computeRisk($payload);
return match (true) {
$score >= $this->riskThreshold => TransactionStatus::Flagged,
$score >= 0.50 => TransactionStatus::PendingReview,
default => TransactionStatus::Approved,
};
}
}No global variables, an immutable object thanks to final readonly, strict input and output types, and a readable match instead of a cascade of if statements.
3. The Laravel Effect
If PHP remains a solid choice for business applications, such as SMB management or e-commerce, it is largely thanks to Laravel.
In the JavaScript ecosystem, you often assemble multiple libraries yourself for authentication, queues, scheduled tasks, database access, and notifications. Laravel provides all of this within a single, coherent, and documented framework.
PHP's execution model has also evolved. Historically, each request starts from scratch: it's simple and avoids memory leaks between users. Today, servers like FrankenPHP, Swoole, or RoadRunner keep the application in memory between requests, which significantly reduces response times.
4. Choosing the Right Tool
Using multiple languages daily helps step out of fan wars:
Python remains the benchmark for machine learning and data analysis.
Next.js / TypeScript excels for rich interfaces and sharing types between client and server.
PHP / Laravel remains remarkably effective for quickly delivering a reliable backend on a simple Linux VPS with Nginx, and maintaining it for years.
PHP is not dead. It simply stopped following trends to become what is expected of an engineering tool: reliable, predictable, and cost-effective.
Sources and references
Share this note
Comments
No comments yet. Be the first to share your thoughts.