WordPress Malware Removal and Hacked Site Repair
Last updated: 14 November 2026 · By Maroof Ahmed
If your WordPress site redirects visitors to spam, shows pages in Google that you never created, has a “This site may be hacked” warning, or your host has suspended it for malware, the site has been hacked. It needs cleaning quickly, because every day the problem stays, more visitors are lost, more spam pages get indexed, and Google trusts the site less. My malware removal service cleans the site, closes the hole the attacker used, removes the damage from Google and protects the site so it does not happen again. It is part of my WordPress services.
Hacks are rarely personal (I explain why in my WordPress SEO guide). Most are automated attacks that scan thousands of sites for an outdated plugin or a weak password. The good news is that almost every hacked WordPress site can be cleaned and recovered, and the steps to prevent it happening again are well known.
Signs your site has been hacked
| Sign | What it usually means |
|---|---|
| Visitors redirected to spam or scam sites, often only on mobile | Malicious code injected into files or database |
| Pages in Google with Japanese, pharma or casino text | Spam pages created on your domain (SEO spam) |
| “This site may be hacked” or “Deceptive site ahead” warnings | Google has detected malware or phishing |
| Host suspended the account | Server-side malware scan found infected files |
| New admin users you did not create | Attacker created a backdoor account |
| Site very slow, emails bouncing or flagged as spam | Server used to send spam or run scripts |
If you see any of these, change your WordPress and hosting passwords now and send me a message through the contact page.
How I clean a hacked site
- Backup the current state. Even infected, so nothing is lost and evidence is kept.
- Scan files and database. Find malicious code, backdoors, fake plugins and injected scripts.
- Clean or replace. Replace WordPress core, themes and plugins with clean copies; remove malicious code from the database and uploads.
- Remove backdoors and rogue users. Delete hidden admin accounts, unknown files and scheduled tasks.
- Close the entry point. Update or remove the vulnerable plugin or theme, reset all passwords and security keys.
- Harden the site. Firewall, login protection, file permissions and monitoring.
- Clean up Google. Remove spam URLs, request reviews of warnings, and check Search Console for manual actions.
Removing spam pages from Google
A common hack, often called the Japanese keyword hack or pharma hack, creates thousands of spam pages on your domain. Even after the site is cleaned, those URLs can stay in Google’s index for months and drag down your real pages. I make sure the spam URLs return the right “gone” status, update the sitemap, use Search Console’s removal tools for the worst ones, and request a review of any security warnings. Then I watch the index until the spam is gone. This recovery work overlaps with technical SEO.
Recovering rankings after a hack
Rankings usually start to return once the site is clean, warnings are removed and spam pages drop out of the index. How long it takes depends on how long the hack ran and how many spam pages were indexed. To help recovery, I check that important pages are indexed and fast, internal links are intact, and no hidden links were added to your pages. If rankings were lost because of the hack, a follow-up SEO audit shows what else needs attention.
Preventing the next hack
Most hacks can be prevented with simple habits: keeping everything updated, using strong unique passwords and two-factor login, removing unused plugins and themes, choosing good hosting, and having daily off-site backups. After cleaning, I set these up and explain them. For ongoing protection, my WordPress maintenance plans keep the site updated and monitored every month.
What to do right now if you are hacked
If you think your site is hacked, these steps (which I also share on my contact page calls) limit the damage while you arrange a proper clean-up. They do not fix the hack, but they stop it getting worse. I go through them with every new client on the first call.
- Do not delete the site or reinstall over it. You may lose content and evidence of how the attacker got in.
- Change passwords. WordPress admin, hosting control panel, FTP, database and email accounts linked to the site.
- Check your users. In WordPress, look under Users for any admin accounts you do not recognise, but do not panic if you cannot remove them yet.
- Tell your host. Hosts often have malware scan results that show which files are infected.
- Pause paid ads. If you run Google Ads or Meta Ads, pause campaigns so you do not pay to send people to a hacked site, and so ad accounts are not flagged.
- Check Search Console. Look under Security Issues and Manual Actions for warnings.
- Get it cleaned properly. Partial clean-ups often miss backdoors, and the hack returns.
Why hacks come back
Many site owners clean a hack themselves or with a quick plugin scan, and a few days later it returns. That happens when the clean-up removes the visible symptoms but leaves a backdoor: a hidden file, a fake plugin, a modified theme file, a rogue admin user, a scheduled task or malicious code in the database. Attackers also return through the same hole if the vulnerable plugin was not updated or removed. My process checks all of these places and closes the entry point, so the site stays clean. Ongoing monitoring through WordPress maintenance catches any new problem early.
Hacked WooCommerce stores
A hacked store is especially serious because it handles customer details and payments. Some attacks inject code into checkout pages to steal card details, add fake payment forms, or redirect buyers. If your store is hacked, I treat it as urgent: clean the site, check every checkout and payment file, rotate payment gateway keys, and review orders and customer accounts for suspicious activity. You may need to inform your payment provider and customers, depending on what was affected. After clean-up, I add extra protection and monitoring for the checkout. See WooCommerce development for store setup.
Hosting and hacks
Cheap shared hosting with poor isolation can let one infected site affect others on the same server, and some hosts run outdated server software. If your site keeps getting reinfected even after a full clean, the hosting environment may be part of the problem. I check server settings, file permissions and PHP version, and recommend a move to better hosting when needed. For small business sites, I usually suggest secure LiteSpeed-based hosting, which you can get at a discount through my Hostinger coupon code page.
Email and blacklists
Hacked sites are often used to send spam email, which can get your domain or server IP listed on email blacklists. Then your normal business emails start landing in spam folders or bouncing. After cleaning, I check major blacklists, request removal where listed, and help set up SPF, DKIM and DMARC records so your emails are trusted again. This matters for businesses that rely on email for quotes, invoices and lead follow-up.
Common types of WordPress malware
| Type | What it does |
|---|---|
| Redirect malware | Sends visitors, often only mobile or Google visitors, to scam, adult or gambling sites |
| SEO spam (Japanese, pharma, casino) | Creates thousands of spam pages on your domain to rank for other people’s keywords |
| Hidden links | Adds invisible links to other sites in your pages or footer |
| Backdoors | Hidden files or code that let the attacker get back in at any time |
| Phishing pages | Fake login pages for banks or services, hosted on your domain |
| Card skimmers | Code on checkout pages that steals payment details |
| Spam mailers | Scripts that send bulk spam email from your server |
| Crypto miners | Scripts that use your visitors’ or server’s power to mine cryptocurrency |
Each type needs a slightly different clean-up and recovery plan. SEO spam, for example, needs the most work in Google after the site is clean, while card skimmers need urgent checks of payments and customer data. I identify the type during the scan, so the clean-up covers everything it touched, including the Google side through technical SEO.
After the clean-up
Once the site is clean, you get a short report: what was found, how the attacker got in, what was removed, what was changed to secure the site, and what to do next. I also check that forms, checkout and key pages work, that Google warnings are cleared or under review, and that a fresh clean backup exists. For the next few weeks, I monitor the site for any sign of reinfection. Most clients then move to a maintenance plan so the site stays updated and watched every month.
If the hack hurt your rankings, recovery can be sped up with a review of important pages, internal links and indexing. Sites that were already strong before the hack usually recover well once Google sees the spam is gone. If rankings stay low, a full SEO audit finds what else needs attention.
Hacked site? Don’t panic
A hacked website is stressful, but it is a common and fixable problem. The most important things are to act quickly, avoid deleting anything in a panic, and make sure the clean-up is thorough so the hack does not return. Once the site is cleaned and protected, the same simple habits keep it safe: updates, strong passwords, fewer plugins, good hosting and regular backups. I explain all of this in plain words during the work, and you can learn more about how I work on my about page.
Frequently asked questions
How quickly can you clean my site?
Many sites can be cleaned within a day or two of getting access, depending on the size of the site and how deep the infection is; I give a timeline once I see the site through the contact page. Google warning reviews can take a few more days.
Will I lose my content?
No. I keep your content, pages and products, and remove only the malicious code and spam, then take a clean backup as in my maintenance plans.
Can a security plugin clean the hack for me?
Security plugins are good at finding known malware and blocking attacks, but they often miss backdoors, database injections and spam pages. They are a useful tool, not a full clean-up. After a proper manual clean, I configure one security plugin as part of ongoing protection, as described on my WordPress maintenance page.
Do you clean sites that are not on WordPress?
My focus is WordPress and WooCommerce. For other platforms, I can still help with the Google side, like spam page removal and security warning reviews, through technical SEO.
What does malware removal cost?
It depends on the size of the site, how deep the infection is and whether Google warnings or spam pages need cleaning. I give a fixed price after a quick look at the site; send the URL through the contact page.
