The Morning I Got That Panic Call
It was 7 AM on a Saturday. A client called me because their ecommerce site was redirecting visitors to a pharmaceutical spam site. Their hosting company had suspended the account. They had no backup from the past three weeks. Their developer had disappeared six months earlier.
That was not my first cleanup job. It was not my last. But it taught me something most security articles miss. The hack was not sophisticated. The attacker found a plugin that had not been updated in two years. They uploaded a malicious file through a known vulnerability. The whole thing took about four minutes.
Most business owners think security means installing a plugin and forgetting about it. That mindset is exactly why sites get hacked. Let me walk you through what actually happens in the real world and what actually stops it.
The Vulnerability Nobody Talks About
Everyone worries about brute force attacks on login pages. I have seen maybe three successful brute force attacks in ten years. The real entry points are boring and mundane.
Abandoned plugins. That contact form plugin from 2019 that still works fine so nobody touches it. The slider plugin the previous developer liked. The SEO plugin that got replaced but never deleted. Each one is a door with a broken lock.
I cleaned a site last month where the attacker entered through a gallery plugin that had not been updated since 2017. The site owner had no idea it was still installed. It was not even active. But the files were there on the server, and the vulnerability was in a file that loaded regardless of activation status.
The fix is not a security plugin. The fix is deleting anything you do not actively use. Every plugin is a potential vulnerability. Every theme you keep “just in case” is a potential vulnerability. If you are not using it, delete it. Not deactivate. Delete.
Why Your Security Plugin Did Not Help
I have cleaned sites with Wordfence installed. I have cleaned sites with Sucuri installed. I have cleaned sites with iThemes Security installed. The security plugin did not stop the hack because the hack happened at the file level, not the WordPress level.
Security plugins are good at blocking known attack patterns at the application layer. They are useless when an attacker already has file access through a vulnerable plugin or compromised FTP credentials. They are useless when the attack happens through a zero day vulnerability that the security plugin does not know about yet.
This is not to say security plugins are worthless. They are a layer. But they are the last layer, not the first. The first layer is server configuration. The second layer is file permissions. The third layer is keeping everything updated. The security plugin is layer four or five.
Most site owners install a security plugin, see the green checkmarks, and assume they are protected. That false confidence is dangerous. It makes them stop paying attention to the things that actually matter.
The Update Problem Nobody Solves
Everyone knows they should update. Few people do it consistently. I understand why. Updates break things. A plugin update conflicts with the theme. A WordPress core update breaks a custom function. WooCommerce updates break payment gateways.
So people stop updating. They wait. They wait until they have time to test. They wait until they can afford a developer to fix whatever breaks. Six months later they have forty seven pending updates and a site that is wide open.
The solution is not “just update everything.” The solution is a staging environment. Every site I manage gets a staging copy. Updates happen there first. If something breaks, we fix it on staging. The live site never sees a broken update.
If you do not have staging, you are gambling every time you click update. That is not a strategy. That is hope. Hope is not a security plan.
For clients who cannot afford managed hosting with staging built in, I set up a local development environment using Local WP or Docker. It costs nothing but time. The alternative is paying me emergency rates to clean a hacked site. That costs a lot more.
File Permissions Are Not Optional
I see this constantly. WordPress files owned by the web server user with write permissions everywhere. The uploads folder set to 777 because “otherwise uploads don’t work.” The wp-config.php file readable by everyone on shared hosting.
Here is the reality. WordPress needs write access to exactly two places. The uploads folder. The upgrade folder during core updates. That is it. Everything else should be read only for the web server user.
On a properly configured server, the web server user cannot modify plugin files. Cannot modify theme files. Cannot modify core WordPress files. If an attacker compromises a plugin, they cannot plant a backdoor in the theme because the file system prevents it.
This requires server level configuration. If you are on cheap shared hosting, you may not have control over this. That is a hosting problem, not a WordPress problem. Move to a host that lets you control file permissions. Or accept that your security ceiling is lower.
I had a client on a popular budget host who got hacked three times in six months. Each time we cleaned it, hardened it, updated everything. Each time they got hacked again through a different vulnerable plugin. The host ran all sites under the same user. One compromised site on the server meant every site was accessible. They moved to a VPS. Problem solved.
The Backup That Wasn’t There
Let me tell you about the backup conversation I have had dozens of times.
Me: Do you have a backup from before the hack?
Client: My host says they do daily backups.
Me: Great. Let’s restore.
Host: The backup contains the hack too. We only keep seven days. The hack happened ten days ago.
Client: What about the plugin backup?
Me: The backup plugin stored files in the uploads folder. The hacker deleted them.
Client: So we have nothing?
Me: Correct.
Offsite backups are not optional. They must be automated. They must be tested. They must go back at least thirty days. They must not live on the same server as your site.
I use a combination of server level snapshots and a plugin that pushes to cloud storage. The plugin is UpdraftPlus or BlogVault depending on the client budget. The key is verification. Once a quarter, I restore a backup to a test environment to confirm it actually works.
An untested backup is not a backup. It is a wish.
User Access Is Usually a Mess
Admin accounts for everyone. The designer who worked on the site two years ago. The SEO agency that lasted three months. The virtual assistant who needed to update a blog post once. The developer who built the site and never had their access revoked.
I audited a site last year with fourteen administrator accounts. Four belonged to people who no longer worked with the company. Two belonged to agencies that had been fired. One was literally “testuser” with password “password123” created during development and never deleted.
The principle is simple. One admin account per person who actually needs admin access. Everyone else gets editor or author or a custom role with exactly the permissions they need. No exceptions.
When someone leaves, their access is revoked that day. Not next week. Not when someone remembers. That day.
Two factor authentication on every admin account. No exceptions. If a plugin or service requires an admin account, create a dedicated account for that service with 2FA enabled. Rotate the password quarterly.
SSL Is Not Security
I have had clients tell me their site is secure because they have the green padlock. SSL encrypts traffic between the browser and the server. It does not prevent SQL injection. It does not prevent cross site scripting. It does not prevent file upload vulnerabilities. It does not prevent brute force. It does not prevent compromised credentials.
SSL is necessary. It is not sufficient. The padlock means your visitors’ data is encrypted in transit. It says nothing about whether your site has been compromised.
This misunderstanding leads to complacency. “We have SSL so we’re good.” No. You have SSL so your customers’ credit card numbers are not readable on public wifi. That is different.
The Hosting Decision Matters More Than You Think
I have moved clients from three dollar hosting to thirty dollar hosting and watched their security problems disappear. Not because the expensive host has magic security. Because the expensive host isolates accounts properly. Because they run current PHP versions. Because they have a web application firewall at the server level. Because their support team actually responds when something goes wrong.
Cheap hosting puts hundreds of sites on the same server with the same user permissions. One vulnerable site compromises the whole server. I have seen this happen. A client’s perfectly maintained site got hacked because another site on the same server had a vulnerable plugin. The attacker jumped accounts through the shared file system.
You do not need enterprise hosting. You need hosting that provides account isolation, current software, server level firewalls, and competent support. That starts around twenty five to thirty dollars a month for a small business site. If that is too expensive for your business, your business model has a problem.
Monitoring That Actually Catches Things
Most security plugins email you when something happens. By the time you read the email, the damage is done. The malicious file is uploaded. The spam pages are indexed. The backdoor is installed.
Real monitoring happens at the file system level. Tripwire style integrity checking. If a core WordPress file changes, you know immediately. If a new file appears in the uploads folder that is not an image, you know immediately. If a plugin file is modified, you know immediately.
I use a combination of server level file integrity monitoring and a service that checks for malware signatures daily. It costs money. It saves far more money in cleanup costs.
The key is alerting that reaches you instantly. Not email. SMS. Slack. PagerDuty. Something that wakes you up at 3 AM. Because that is when attackers work. They know you are asleep.
What a Real Cleanup Looks Like
When I get a hacked site, here is the process. It takes four to eight hours minimum.
First, take the site offline. Maintenance mode. No visitors see the compromised site. No search engines crawl it.
Second, create a complete forensic backup. Everything. Database. Files. Logs. This goes to secure storage for analysis later.
Third, identify the entry point. Check access logs. Check file modification timestamps. Check for unauthorized admin users. Check for suspicious files. This tells you how they got in so you can close that specific door.
Fourth, nuke the WordPress installation. Keep only wp-config.php and the uploads folder after scanning every single file in uploads for malware. Delete everything else. Core files. Plugins. Themes. All of it.
Fifth, fresh install of WordPress. Fresh install of every plugin from the official repository. Fresh install of the theme from a clean source. Restore the database from a known clean backup.
Sixth, change every password. Every API key. Every salt in wp-config.php. Every hosting credential. Every FTP credential. Every database credential. Assume everything the attacker could have seen is compromised.
Seventh, implement the hardening that should have been there. File permissions. Security headers. Disable file editing. Disable XML-RPC if not needed. Restrict REST API. Limit login attempts. Two factor authentication.
Eighth, monitor aggressively for the next two weeks. Daily file integrity checks. Daily malware scans. Watch the logs.
This is not something a security plugin does for you. This is manual work by someone who knows what they are looking for. That is why cleanup costs what it costs.
The Conversation I Have With Every New Client
When a new client comes to me, I ask three questions.
When was the last time you restored a backup to verify it works?
Who has admin access to your site right now?
When did you last update every plugin, theme, and core file?
The answers tell me everything I need to know about their security posture. Usually the answers are “never,” “I don’t know,” and “six months ago.”
Then I give them a choice. Pay me a monthly retainer to handle all of this properly. Or sign a waiver acknowledging that I warned you and you accepted the risk.
Most choose the retainer after I show them the invoice for the last cleanup I did for a similar site. Prevention is boring. Cleanup is terrifying. The price difference is a factor of twenty.
What You Can Do This Week
Delete every plugin and theme you are not actively using. Not deactivate. Delete.
Audit every user account. Remove anyone who does not need access. Enforce two factor authentication on the rest.
Check your backup situation. When was the last successful offsite backup? When did you last test a restore?
Update everything on a staging site first. Then push to live.
Ask your host about account isolation and server level firewalls. If they don’t know what you’re talking about, start looking for a new host.
Install a file integrity monitoring tool. Configure it to alert you instantly, not daily.
None of this is exciting. None of it feels productive. You will not see a visible improvement in your site. That is the point. Security done right is invisible. You only notice it when it fails.
The Hard Truth
You will not be perfectly secure. Perfect security does not exist. The goal is to make your site difficult enough that attackers move to an easier target. There are millions of WordPress sites. The ones that get hacked are the ones with open doors.
Close your doors. Delete the junk. Update religiously. Backup obsessively. Monitor constantly. Pay for good hosting. Treat admin access like keys to your safe.
Or don’t. But when you get that 7 AM call, don’t say nobody warned you.