Since the PHP2Shell vulnerability of October 2026, many managers have received the same advice from their host: “you need to move to PHP 8”. Put like that, it sounds like one more update, like the one on your phone. For an application built in the PHP 7 era, it is rarely that simple. The problem is less the PHP version than the way your program was built. And that is often what needs to be reviewed.
The day the update breaks the site
The scenario is a classic. The host announces it is moving its servers to PHP 8. On Monday morning, the site shows a blank page. Or worse: the storefront displays normally, but payment fails without any error message, and nobody notices until the first customer calls.
The supplier urgently restores the old version and everything runs again. Except that the old version is precisely the one that no longer receives security fixes. Back to square one, with bad news on top: we now know the site cannot cope with change.
PHP 8 tolerates far fewer approximations

Think of the wiring in a house from the 1990s. It works, the lights come on. But the day you renovate, the electrician tells you it no longer meets the standards and part of the fuse board has to be redone. Moving from PHP 7 to PHP 8 is much like that.
PHP 7 let small errors in the code slide. It displayed a warning in a file nobody read, then carried on. PHP 8, on the other hand, stops dead on many of these errors. Code that “worked anyway” for ten years starts to crash.
There is something sneakier. Some calculations give a different result without warning. A real example: PHP 7 considered a word like “abc” equal to the number zero; PHP 8 does not. If a stock or promo-code test relied on that quirk, it changes behaviour without a single error message.
Finally, some instructions have simply disappeared from PHP 8, and each new version (8.2, 8.4, 8.5) has marked others as deprecated. Before changing server, an application written for PHP 7 must therefore be reviewed in detail.
The framework trap: the structure ages along with the rest
Most applications are not written from scratch. They rely on a framework or a CMS (Laravel, Symfony, MODX, Zend…), a kind of ready-made frame on which the developer built your features. Each version of that frame works only with certain versions of PHP. Changing PHP therefore means changing the frame, and that is where the project grows.
Laravel
Recent versions require a recent PHP: Laravel 13, released in March 2026, requires at least PHP 8.3. An application left on Laravel 5 or 6 therefore has to cross seven or eight major versions, each with its own changes. Even a Laravel 11 project is already no longer covered: its security support ended on 12 March 2026.
MODX
To benefit from a recent PHP, you have to move from MODX 2 to MODX 3, and this update breaks compatibility in several places. Official MODX support acknowledges it: some extensions were never adapted, in particular those that do not handle PHP 8. Users also regularly report sites crashing after the update.
Zend Framework and abandoned frameworks
Zend Framework has not been developed since 2020; the project was taken over under another name, Laminas. There is therefore no next version to install; you have to migrate to something else.
To return to the house image: changing the frame means taking down part of the roof. The parts that rested on it (your business code) have to be redone one by one.
The building blocks nobody looks after any more
A business application uses dozens of modules written by others: online payment, PDF invoice generation, email sending, the link to your accounting software. As long as their authors maintain them, they keep up with new PHP versions. When the author stops, the module stays frozen.
Take SimpleCart, an online shop module for MODX: it will never be adapted to MODX 3, and its support ended on 31 December 2025. A shop built on it cannot simply move up a version. The whole checkout process has to be replaced.
It is a bit like a fitted kitchen whose manufacturer has closed down: the day the oven gives out, you cannot find a part, and the replacement model does not have the same dimensions. You then have to alter the cabinets around it.
In-house development: where it gets stuck the most
Many Swiss SMEs run on an application custom-built ten or fifteen years ago, often a customer extranet or an order portal for resellers. It works and everyone knows it. The developer who wrote it, though, has often long since left.
The problem is that your business rules are buried in this code. The calculation of shipping costs for Ticino or the discount granted to the long-standing customer: nobody wrote them down anywhere else. And there are generally no automated tests, that is, no program that checks after every change that these calculations still give the right result.
Modifying this code for PHP 8 is therefore working blind. You fix one line, and a discount disappears three screens away without anyone seeing it. In that case, cleanly rewriting the sensitive parts, with tests, often costs less than patching the existing code for months.
Update, migration or rewrite: how to know where you stand

Not every application needs to be rewritten, and a supplier who tells you otherwise without having looked at your code deserves to be questioned. There are three paths.
The update
Your application is recent, on a framework that is still maintained. A few lines are adapted and tested before switching over. It is like a service at the garage.
The step-by-step migration
The foundations are sound, but the framework is several versions behind. It is brought up version by version, fixing issues as we go. It takes longer, but the application stays in service throughout the work, like renovating room by room while you live in the house.
The rewrite
The frame is too old and nobody really knows how the code works any more. The application is rebuilt on a modern base, taking over your business rules one by one. We do not redo everything at once: the most critical parts come first.
A grid to place yourself
| Criterion | Rather an update | Rather a step-by-step migration | Rather a rewrite |
|---|---|---|---|
| Current PHP version | 8.2 or later | 7.4 à 8.1 | 7.3 or earlier |
| Framework or CMS | Version still supported | One or two versions behind | Abandoned, or very far behind (Laravel 5, MODX 2, Zend) |
| External modules | All maintained | A few to replace | Several abandoned, including key modules |
| Automated tests | Yes | Partial | None |
| Knowledge of the code | The original team is still here | Documented code, team has changed | Developer gone, nothing written down |
If most of your answers fall in the last column, a rewrite will be needed. The diagnosis will mainly serve to decide where to start.
What makes the budget vary
We are often asked for a price over the phone. Honestly, it is impossible to give one without having opened the code, for the same reason a contractor does not price a renovation without looking behind the walls. What weighs most in the balance:
- the size of the application, that is, the number of screens and functions actually used (often fewer than what exists);
- the connections with other software, such as accounting, the ERP, payment or logistics;
- the state of the existing code and its documentation;
- the volume and cleanliness of the data to be carried over;
- the languages, when the application runs in French, German and Italian.
A first diagnosis of a few days makes it possible to decide between the three paths and to cost the project with a reasonable margin. Without it, any quote is a blind estimate.
And if we do nothing?
The temptation is understandable: the application works, we will see next year. But the calendar does not wait for you.
PHP versions 7.4, 8.0 and 8.1 received no patched release for the PHP2Shell vulnerability of October 2026, only a minimal fix to compile yourself (see our article PHP2Shell: why your PHP 7 or 8.1 site is exposed). PHP 8.2 will in turn be dropped on 31 December 2026. Every month spent on these versions is a month without a spare lock.
There is also a less visible cost. The older the code gets, the fewer developers are willing to take it on, and the longer each small change takes. Not to mention the company’s responsibility: the nLPD requires adequate security measures for customer data, which an unpatched version makes hard to defend.
Finally, even a modern application needs regular maintenance. Laravel 12, for example, stops receiving security fixes after 24 February 2027. One version upgrade a year costs far less than a rewrite every ten years.
The real subject is the frame
Moving from PHP 7 to PHP 8 on a business application is rarely a matter of server settings. If your application relies on an old Laravel, on MODX 2 or on in-house development without tests, a good part of its structure will need to be reworked. Better to know it before starting the work than in the middle of it.
In the next article, we get concrete: how a rewrite in PHP 8.5 works, step by step, and what your business gains from it.
Frequently asked questions
Can you move straight from PHP 7.4 to PHP 8.5?
Technically yes, but rarely without work on the code. All the incompatibilities accumulated between 8.0 and 8.5 hit at once, and the framework generally has to keep up.
My application is built on Laravel, does it necessarily need a rewrite?
No. An application on Laravel 9 or 10 with clean code can often be migrated version by version. A rewrite becomes worthwhile when the gap is large (Laravel 5 or 6) and the code has no tests.
What about a MODX 2 site?
It all depends on the extensions used. If they exist in a MODX 3 version, migration is feasible. If key extensions are abandoned, they have to be replaced, or even the site rethought.
How long does a migration take?
From a few days for a simple update to several months for a rewrite. The initial diagnosis is precisely what is used to estimate it.
Sources
- Laravel, 13.x release notes and support policy
- Benjamin Crozat, Laravel versions and support status
- MODX Support, upgrading from Revolution 2 to 3
- MODX Forum, upgrade problems with PHP 8
- modmore, end of SimpleCart support




