A paid caching plugin is supposed to make your WordPress site faster. Since 25 November, one of the most popular ones has also been a way in. Attackers are exploiting a flaw in WP Rocket that lets them place their own PHP code on a site and run it, without logging in.
WP Rocket fixed the problem on 19 November, so the update already exists. The catch is that many sites haven’t installed it, and some can’t, because their license has expired. Updating also doesn’t clean up anything an attacker left behind before the fix went in. The checks below start with the simplest question: whether your site is exposed at all.
What the WP Rocket Flaw Does
The flaw is tracked as CVE-2026-125812 and has a severity score of 9.8 out of 10, which puts it in the critical range. If the label is new to you, the guide to what a CVE is and how the scores work explains it in plain terms.
WP Rocket runs a small script in your visitors’ browsers that measures each page and reports the results back to your site. That report goes to a public address, so anyone can send one. Before the fix, WP Rocket didn’t check the web addresses in those reports carefully enough. A crafted report could make your site download a file from the attacker’s server and save it as a PHP file, the programming language WordPress itself is written in. Once that file sits on your server, it runs like any other part of your site.
According to Patchstack, the security company that found the attacks, the first attempt came on 25 November at 15:27 UTC. Within a day it was automated, and Patchstack blocked tens of thousands of attempts on 26 November alone. Those are blocked attempts, not confirmed hacks, but they show that bots are scanning for vulnerable sites at scale.
Is Your Site Affected?
WP Rocket says the flaw affects versions 3.15 through 3.24.1, and only when at least one of two features is switched on:
- LazyLoad for CSS background images
- Self-host Google Fonts
Both are off by default, but they’re popular on sites that have been tuned for speed. To check, open WP Rocket > Page Optimization > Image & Media in your dashboard. On versions older than 3.24, the settings are under the Media tab instead.
Your version number is on the Plugins page, under WP Rocket. If it’s 3.24.2 or higher, the hole is closed. If it’s lower and either setting is on, treat the site as exposed since at least 25 November.
Update Now, Even If You Think You’re Safe
Version 3.24.2 contains the fix, and 3.24.3 followed on 26 November. Update to the newest release you can get. WP Rocket’s changelog describes the fix in one quiet line about better validation of cached CSS, font and preconnect files, so it’s easy to have skipped this update without noticing that it mattered.
Update even if both settings are off on your site today. You may turn one of them on later, or someone else with access to the dashboard might, and an old version would then be exposed straight away.
If Your WP Rocket License Has Expired
WP Rocket is a paid plugin, and updates only arrive while your license is active. Plenty of sites still run an old copy that was bought once and never renewed, often set up by a developer who has since moved on. Those sites can’t get 3.24.2 through the dashboard.
WP Rocket’s own advice for this case is to switch off both features. Go to WP Rocket > Page Optimization > Image & Media, turn off LazyLoad for CSS background images and Self-host Google Fonts, save, and reload the page to confirm both are still off. If you manage several sites, do this on each of them. The full steps are in WP Rocket’s security advisory.
That closes the door, but it leaves you on an outdated plugin that won’t get the next fix either. Renewing the license or moving to a caching option you can keep updated is the better long term answer. Many hosts include their own page caching, which removes the need for a paid caching plugin altogether.
Why Updating Isn’t Enough
An update stops new attacks. It does nothing about a PHP file an attacker placed on your server before you updated, and that file keeps working until someone deletes it. If your site ran an affected version with either setting on after 25 November, check for leftovers.
Patchstack lists these signs of a successful attack:
- PHP files you don’t recognise in
wp-content/wp-rocket-config/,wp-content/uploads/or directly inwp-content/ - File names that look like
wp-media-something.php - Connections from your server to unfamiliar addresses, which your host can see in its logs
The uploads folder should normally hold images and documents, not PHP files, so any PHP file there is a red flag. If you find one, don’t just delete it and move on. Attackers often leave more than one way back in, and the walkthrough for cleaning up after a malicious plugin release covers the steps that apply here too.
What Your Host Can Do
Your hosting company can take a lot of this work off your hands. Ask whether its malware scanner has flagged anything on your account since 25 November, and whether it keeps backups from before that date.
A web application firewall can filter the malicious reports before they reach WordPress, and some hosts and security services added rules for this flaw within days, so it’s worth asking whether yours did. Malware scanners such as Imunify360, which many shared hosts run, look for the kind of PHP file this attack leaves behind.
Backups matter most if a scan does find something. A copy from before 25 November lets you compare files or roll back, and the guide to backing up a WordPress site explains how to keep your own copies so you don’t depend on the host alone. If keeping plugins patched is a job you’d rather hand over, managed WordPress hosting usually includes update handling and malware scanning in the price.
Frequently Asked Questions
Is WP Rocket safe to use now?
Yes, on version 3.24.2 or later. The flaw is fixed in that release, and 3.24.3 is the newest version as of late November 2026. Older versions are only exposed when LazyLoad for CSS background images or Self-host Google Fonts is switched on.
My WP Rocket license has expired. What should I do?
Turn off LazyLoad for CSS background images and Self-host Google Fonts under Page Optimization > Image & Media, then save. That blocks this attack, but you’ll stay on an old version, so renewing or switching to your host’s built in caching is the safer plan.
How do I know if my site was hacked through WP Rocket?
Look for PHP files you don’t recognise in wp-content, wp-content/uploads and wp-content/wp-rocket-config, especially names starting with wp-media. Ask your host to run a malware scan and to check its logs for unusual outgoing connections since 25 November.
Does updating WP Rocket remove malware?
No. The update only stops new attacks. Any file an attacker planted before you updated stays on the server and keeps working until it’s found and removed.
Am I safe if both settings were always off?
According to WP Rocket, the flaw can only be exploited when at least one of the two features is on. If both were off the whole time, this attack couldn’t reach your site, but you should still update so that switching one on later doesn’t open the hole.