The worst part of a hacked website is rarely the website. It is the Google warning that appears next to your business name, telling every customer who searches for you that the site may harm their computer.
Getting that removed takes days. Preventing it takes a few hours of work you can do this week. This is how WordPress sites in Kenya actually get compromised, how to tell whether yours already is, and what a proper clean-up involves.
How WordPress Sites Actually Get Hacked
Almost never because somebody targeted your business. Bots scan the whole internet for known weaknesses and take whatever they find. In order of how often we see it:
- An out-of-date plugin or theme. Patchstack recorded 11,334 new vulnerabilities across the WordPress ecosystem in 2025, with 91% of them in plugins.
- A weak, reused or shared admin password, with no two-factor authentication and no limit on login attempts.
- An abandoned plugin, deactivated but never deleted, whose files still sit on the server.
- An unsupported PHP version, or a server the host has not patched.
- A compromised supply chain, where a legitimate plugin update itself carries malicious code.
- A stolen hosting or FTP credential, often from a developer's infected laptop.
What Has Been Happening Lately
Four incidents from recent weeks, each illustrating a different route in:
| Incident | Date | Lesson |
|---|---|---|
| WordPress core flaw (CVE-2026-87902), path traversal leading to code execution, fixed in WordPress 7.1.2 | 22/09/2026 | Even core needs prompt updating. Patchstack saw exploitation attempts within hours of disclosure |
| Rank Math PRO supply chain compromise: a malicious version was live for about eleven hours | 15 to 16/10/2026 | A trusted plugin can turn hostile for a short window. Updating blindly at 3am is not always safest |
| UpdraftCentral key compromise: attackers with valid dashboard keys installed backdoor plugins and hidden admin accounts | 18 to 19/10/2026 | Remote management tools are a master key. Treat their credentials like your bank login |
| PHP2Shell (CVE-2026-109618 and CVE-2026-109619), critical flaws in PHP itself | 21/10/2026 | Some problems live below WordPress entirely and are fixed only by the host updating PHP |
The PHP one matters most this month, and we have written it up separately in what the PHP security alert means for Kenyan websites.
Signs You Are Already Compromised
- Administrator accounts you did not create
- Visitors arriving from Google being redirected somewhere else, while direct visits look normal
- Pages you never wrote appearing when you search
site:yourdomain.co.ke, often about pharmaceuticals, loans or gambling - New PHP files in
wp-content/uploads, where no PHP file belongs - Your host suspending the account, or warning about unusual outbound email
- A warning in Google Search Console under Security Issues
- Customers reporting warnings that you cannot reproduce on your own phone
Blacklists, and What They Cost You
Once Google's Safe Browsing system flags a site, the damage spreads fast. Chrome, Firefox and Safari show a full-page red warning. Your Google ads may stop. Some email providers start treating mail from your domain as suspicious. And the warning is visible to everyone who searches your business name, including customers who were never going to visit the site.
Getting removed requires cleaning the site properly and then requesting a review through Google Search Console. A review usually takes a few days, and a failed review because the site was not fully cleaned restarts the clock. This is the main reason a rushed clean-up costs more than a careful one.
A Proper Clean-Up, in Order
The sequence that actually works
- Take a copy of the site as it is now, infected and all, before changing anything. You need it for evidence and for comparison.
- Put the site into maintenance mode with a 503 status, so search engines treat the outage as temporary.
- Preserve the logs. Access and error logs from at least 48 hours before the first symptom. Without them you will never learn how they got in.
- Find the entry point. Compare core and plugin files against clean copies, look for recently modified files, check for unexpected scheduled tasks and database-level injections.
- Clean or rebuild. Replace core, themes and plugins with fresh copies from source rather than trying to disinfect files one by one. Keep only your database and uploads, and scan those.
- Remove persistence. Unknown admin users, backdoor plugins, modified
.htaccess, injected code in theme functions and database options. - Rotate every credential: WordPress admins, database, hosting, FTP, API keys, email. Assume everything on that server is known to the attacker.
- Patch everything, including the PHP version, before going back online.
- Request a Google review once the site is genuinely clean, and watch Search Console for a week.
The step people skip is the fourth one. Restoring last week's backup without finding the entry point means the same bot returns within days, and the second compromise is usually worse because the first one left a door open.
Hardening So It Does Not Happen Again
The WordPress project's own hardening guidance, plus what we apply on every site we maintain:
- Update core, plugins, themes and PHP on a schedule, tested on a staging copy first.
- Delete what you do not use. A deactivated plugin is still code on your server.
- Two-factor authentication on every admin, plus limits on failed logins.
- Least privilege: files 644, directories 755,
wp-config.phptighter, and onlywp-contentwritable by the web server. - Disable the file editor with
define( 'DISALLOW_FILE_EDIT', true );so a stolen admin login cannot edit code directly. - Block PHP execution in the uploads folder, which stops the most common backdoor outright.
- Daily off-site backups, with a restore you have tested at least once.
- A firewall in front, and monitoring that tells a person when something changes.
When to Call Someone
Do it yourself if the site is small, you have a clean backup from before the problem, and you can find the entry point. Call for help when any of these is true:
- The site takes payments, holds customer data, or is your main sales channel
- Google has already flagged it, or your host has suspended the account
- You cannot find how they got in, or the infection returns after cleaning
- You have no backup from before the compromise
- It has happened more than once this year
We clean and harden hacked WordPress sites, and malware removal is included in every maintenance plan from KES 5,000 a month rather than billed as an emergency. If you are not on a plan, send us the site and the hosting login and we will quote the clean-up before starting.
Frequently Asked Questions
How do WordPress sites actually get hacked?
Almost never because somebody targeted your business. Bots scan the internet for known weaknesses. In order: an out-of-date plugin or theme, a weak or reused admin password with no two-factor, an abandoned plugin that was deactivated but never deleted, an unsupported PHP version, a compromised plugin update, or stolen hosting credentials.
How do I know if my website is infected?
Look for admin accounts you did not create, visitors from Google being redirected elsewhere, pages you never wrote appearing when you search site:yourdomain, new PHP files in your uploads folder, your host suspending the account, or a warning in Search Console. Always test in a private window from a phone, arriving through a Google search, because malware often hides from the logged-in owner.
What happens when Google blacklists my site?
Chrome, Firefox and Safari show a full-page warning to anyone visiting, the warning is visible to everyone searching your business name, ads may stop and email deliverability can suffer. Removal requires cleaning the site properly and requesting a review in Search Console, which takes days, and a failed review restarts the clock.
Can I just restore a backup?
Not on its own. If you do not find how they got in, the same bot returns within days and the second compromise is usually worse. Preserve logs, find the entry point, rebuild from clean sources, remove persistence such as unknown admins and backdoor plugins, rotate every credential, patch everything including PHP, and only then go back online.
What recent WordPress incidents should I know about?
A WordPress core flaw fixed in version 7.1.2 on 22 September 2026 that was being exploited within hours. A Rank Math PRO supply chain compromise where a malicious version was live for about eleven hours on 15 and 16 October. An UpdraftCentral key compromise on 18 and 19 October that installed backdoor plugins. And the critical PHP flaws of 21 October, which are fixed by the host updating PHP rather than by updating WordPress.
Do you clean hacked websites?
Yes. Malware removal is included in our maintenance plans from KES 5,000 a month rather than billed as an emergency. If you are not on a plan, send us the site and hosting login and we will quote the clean-up before starting.
Hacked, flagged or suspended? Send it to us
We will find how they got in, clean it, patch it, restore it and harden it so that route closes. If your site is fine, we will tell you that too and show you the three things to fix before it is not. Talk to us on WhatsApp at +254 722 334 188, email hello@wpfoss.ke, or call +254 709 384 200.
Get It Cleaned and ProtectedRelated: Security Audit Checklist · Free Website Checkup · Patchstack report · WordPress hardening guide