Next.js or PHP? The Better Question Is Who Patches Your Site

Between November 11 and November 19, 2026, the software under most small business websites needed three urgent repairs. Apache, a widely used web server, fixed a critical flaw in its HTTP/2 module. NGINX, another popular web server, fixed two HTTP/2 bugs among ten fixes. Then PHP, the programming language that runs WordPress, shipped a critical security release.
If your website runs on WordPress, at least one of those repairs was yours, whether or not anyone mentioned it. If someone has been nudging you toward Next.js, this was their week to say "told you so."
We build Next.js sites for a living, so take the next sentence as an admission against interest. PHP is not the villain of this story, and Next.js has needed emergency patches too, including one that attackers used in the wild. The useful question is not which technology is safer. It is who patches your site, how fast, and how much of your site needs patching in the first place.
What PHP actually shipped, minus the panic
Dates first, because they got muddled in the retelling. php.net's November 18 entry was an advance notice, titled "Upcoming Critical PHP Security Release." The fixes themselves arrived on November 19: PHP 8.5.13, 8.4.28, 8.3.37 and 8.2.36, according to the PHP project's news archive, read in November 2026.
The notice rated the worst issues critical, then added a sentence most headlines skipped: "The issues rated CRITICAL require either non-default configuration or uncommon setups." The most serious one lives in PHP-FPM, the program that passes web requests to PHP on many servers. It only bites when the web server reuses its connections to PHP, which the CVE record for the flaw, read in November 2026, says "is not the default in nginx or Apache." And no exploitation of the November flaws had been reported as of November 20, 2026; the CISA assessments attached to the records of the critical issues showed none.
That is the calm half. Here is the other half. Two of the November fixes finish work the PHP project started in October, when it patched the critical flaws that security researchers named PHP2Shell (a name php.net itself never uses). One of the PHP project's own November advisories describes itself as "an incomplete fix" for an October bug. So a site that patched diligently in October still needs this release. The October flaws were not theoretical, either: CISA added both to its Known Exploited Vulnerabilities catalog on October 26, 2026. Our PHP2Shell guide covers that release.
Why the language is not the problem
PHP has carried the web's workhorse sites for a long time, and it does the job. The November bugs are ordinary software bugs, the kind every large project ships and then fixes. The exposure comes from how a classic PHP site is arranged.
Every time a visitor opens a page on a typical WordPress site, the server runs PHP. It loads WordPress, the theme and every active plugin, asks the database for the content and assembles the page on the spot. That happens on a server the owner usually does not control, because on shared or managed hosting the host owns the PHP installation. A PHP flaw therefore turns into a relay race with three runners: the PHP project writes the fix, the host builds and installs it, and somebody restarts PHP so the fixed code actually loads.
That last leg is not trivia. Liquid Web's Cloud Sites status page posted on November 19 that "PHP version updates may require PHP-FPM or other PHP services to be restarted to ensure the security fixes are fully applied." That host moved quickly: its advisory went up the morning of the release and a list of patched packages followed the same afternoon, according to its status page, read in November 2026. That is what a responsive host looks like. Notice, though, that the owner of a site on that server did none of it and could have hurried none of it.
There is a fourth runner owners forget: the plugin authors. A patched PHP only helps a site that can run it. When one old plugin breaks on a newer version, the whole site stays behind, which is why replacing risky plugins is security work and not housekeeping.
Next.js has patch days too
Fairness requires a count. The Next.js project's security advisories page on GitHub lists 65 advisories published between January 1, 2025 and November 20, 2026, by our count through GitHub's data in November 2026. Some were serious:
- March 2025: an authorization bypass in Next.js middleware, the code that runs before a page is served (CVE-2025-29927), rated critical at 9.1.
- December 2025: remote code execution in React Server Components, the part of React that runs on the server (CVE-2025-55182). CISA added it to the exploited list on December 5, 2025, and its catalog marks it as known to be used in ransomware campaigns.
- August to October 2026: three more critical remote code execution advisories: one for servers hosted on Windows, one in the tool that draws social sharing images, and one in the Image Optimization feature when SVG files are used. That last one traced to an outside image library and was fixed in Next.js 15.5.28 and 16.4.1.
- November 3, 2026: seven medium advisories, fixed in 16.4.5.
So nobody gets to claim Next.js needs no patching. It does, sometimes urgently. What differs is where the flaws live and who applies the fix.
Same week, two chains of custody
Here is how a critical flaw travels to each kind of site.
| Step | Classic PHP site on shared hosting | Next.js site on a managed platform |
|---|---|---|
| Who writes the fix | The PHP project, plus WordPress, theme and plugin authors | The Next.js and React projects, plus outside library authors |
| Who installs it | The host, on its schedule, for the PHP layer | Your developer: update the package, rebuild, redeploy |
| What gets restarted | PHP processes on a server shared with other sites | Nothing separate; the new build replaces the old one |
| What can block it | One plugin or theme that breaks on the newer version | Your own code breaking on the new Next.js version |
| What an attacker can reach | PHP, on every page view | Only the parts of the site that run server code |
Neither column wins automatically. The left one hands the work to a host who does it for thousands of sites at once, which is efficient right up until your site is the one that cannot take the update. The right one hands the work to your developer, which is excellent if that developer answers the phone and less excellent if the person who built your site moved to another state in 2023 and changed numbers.
The pages that run no code
The real structural difference is the last row of that table. A Next.js page can be prerendered: built into a plain HTML file ahead of time and served as a file. When a visitor asks for that page, no program assembles it. There is no PHP to exploit on a page that runs no server code, and no Next.js server code to exploit either. A file has very little to say to an attacker.
Most real Next.js sites are not entirely static, though. Contact forms, logins, image resizing, previews and anything personalized run on a server. Look back at that list of advisories: the middleware bypass, the server components flaw and the image optimization flaw all lived in exactly those server parts. A Next.js site that leans on server features for everything carries a server's risks. One that serves most pages as files, and keeps its server code small and specific, gives an attacker much less to aim at.
Owners who want to keep WordPress can have some of both. Our Next.js route out of PHP2Shell describes putting WordPress behind a prerendered front end, where only editors can reach it. The broader trade, including what you give up, is in our WordPress vs Next.js guide.
The same design also answers the speed question. A prerendered page is fast for the same reason it is hard to attack: nothing happens when you ask for it. We made that case at length in why a custom Next.js site can beat WordPress and Webflow.
Who should move, and who should stay
Stay on PHP, patched, if most of these are true:
- Your host installed the November 19 release, restarted PHP and will say so in writing.
- Your site runs PHP 8.3 or newer, or 8.2 with a plan, since php.net ends 8.2 security support on December 31, 2026.
- Your plugins are maintained and a PHP upgrade does not break anything.
- Someone checks the site after each release, whether that is you, a staff member or a maintenance plan.
Think seriously about moving if most of these are true:
- Your site is stuck on PHP 8.1 or older because something breaks on newer versions. php.net lists 8.1 and older as end of life and announced no November fixes for them.
- You pay someone to clean up after a plugin more than once a year.
- Your pages change weekly at most: services, service areas, a menu, a portfolio. Those are ideal prerendered pages.
- You were already planning a redesign, so the rebuild cost is partly spent anyway.
Moving is a project, not a switch. Our WordPress to Next.js page lays out how a move works, and should I leave WordPress argues both sides without pretending the answer is always yes.
What to do this week, and when you do not need us
Start with one email to your host: which PHP version is my site on, was the November 19 release installed, and was PHP restarted afterward? Ask for the answer in writing. If the reply is vague, or the version is 8.1 or older, that is your cue.
We can help in three sizes. The free website health check is a quick look at what your site is running. Our website security services start from $575, depending on complexity, with a written estimate before work starts. If the site is already misbehaving, emergency repair responds the same business day. And if you would rather someone else watch the patch calendar every month, hosting and maintenance starts at $55 a month.
You do not need us if your host confirmed the patch, your PHP is 8.3 or newer and your plugins update without drama. That is a well-run WordPress site. Keep it, and keep an eye on the code you did not write, which is the lesson of the Optimizely incident from this same week. If you want to talk through a move, contact us or call (210) 346-0848.
Read the series
- Next.js versus PHP: who patches your site (you are here)
- Your host is still patching PHP 5.4
- Three server advisories in eight days
- The speed feature your host switched off
- The plugin blocking your PHP upgrade
- Shared hosting, shared risk
- Five questions for your host
Frequently asked questions
Is PHP less secure than Next.js?
Not as a language. Both projects publish security fixes regularly, and Next.js has had critical advisories, including one CISA lists as exploited. The difference is structural. A classic PHP site runs code on every page view, on a server your host controls. A prerendered Next.js page is a file that runs no code when a visitor opens it. Server features on a Next.js site still need patching.
Was anyone hacked through the November PHP flaws?
No exploitation of the November 19 PHP flaws had been reported as of November 20, 2026, according to the CISA assessments attached to the CVE records. That is not the same as saying nobody will try. The October PHP flaws, by contrast, were added to CISA's Known Exploited Vulnerabilities catalog on October 26, so patching promptly is still the right call.
I updated PHP in October. Do I need to update again?
Yes. The PHP project's own November advisories describe part of the release as completing an incomplete October fix. A site that moved to 8.5.12, 8.4.27 or 8.3.36 in October still needs 8.5.13, 8.4.28 or 8.3.37. On 8.2, the November release is 8.2.36. Ask your host to confirm the exact version and that PHP was restarted afterward.
Does a Next.js site ever need emergency security patches?
Yes. The Next.js project published 65 security advisories between January 2025 and November 2026, several rated critical. The fix is usually a package update, a rebuild and a redeploy, which your developer or hosting arrangement has to do promptly. Sites that keep server features small are exposed to fewer of those advisories, but no site is exempt.
What does prerendered mean, and why does it matter for security?
A prerendered page is built into a finished HTML file before anyone visits, then served as that file. No program runs to assemble it when a visitor arrives, so there is no interpreter for an attacker to send a crafted request to on that page. Forms, logins and image processing still run server code, and that code still needs updates.
Should I move my WordPress site to Next.js because of this week?
Not because of one week. Move if your site is stuck on old PHP, if plugins keep causing repairs, or if you were planning a redesign anyway. If your host patched quickly, your PHP is current and your plugins update cleanly, a well-kept WordPress site is a reasonable thing to own. Patch first either way, then decide calmly.





