How to Recover a Hacked WordPress Site (Step by Step)
Signs your WordPress site is hacked and a step-by-step recovery plan: contain, change credentials, restore or clean, remove backdoors, update, request…

Because WordPress is so popular, it's also a favourite target for automated attacks. The good news is that most successful hacks exploit preventable weaknesses: outdated plugins, weak passwords, pirated themes and poor hosting. This checklist covers the steps that stop the vast majority of attacks.
Key takeaways
- Keep WordPress core, themes and plugins updated.
- Use strong passwords and two-factor authentication for every admin.
- Install only reputable plugins and never use nulled themes.
- Run daily off-site backups and test restores.
- Add a firewall and monitor for changes.
Enable automatic minor core updates, update plugins and themes weekly after checking compatibility, and remove anything inactive. Outdated plugins are the most common entry point for attackers.
Install from WordPress.org or reputable vendors, check update frequency and reviews, and never use pirated ("nulled") themes or plugins, which often contain malware.
Security plugins add malware scanning, login protection and file change detection. A web application firewall (plugin-based or at the CDN level, such as Cloudflare) blocks malicious requests before they reach WordPress.
| Setting | Recommendation |
|---|---|
| File editing in dashboard | Disable with DISALLOW_FILE_EDIT |
| wp-config.php | Protect and move secrets out of web root where possible |
| File permissions | Folders 755, files 644, wp-config 600/640 |
| XML-RPC | Disable if not needed |
| Directory listing | Disable |
| PHP version | Use a supported version |
Take automatic daily backups stored off the server, keep at least 30 days of history and test restoring regularly. See WordPress backup strategies.
Choose hosting with account isolation, malware scanning, automatic backups and up-to-date server software. Managed WordPress hosting adds extra protection.
Watch for new admin users, file changes, unusual traffic and Google Search Console security warnings. Set up uptime monitoring with alerts.
Follow a clear recovery process. See how to recover a hacked WordPress site.
| Plugin | Strengths |
|---|---|
| Wordfence | Firewall, malware scan, login security |
| Sucuri Security | Auditing, hardening, cloud firewall option |
| Solid Security | Hardening options, 2FA, brute-force protection |
| CDN firewall (e.g. Cloudflare) | Blocks threats before they reach the server |
Choose one main security plugin to avoid conflicts.
Keep payment plugins updated, use gateways that handle card data off-site, limit admin and shop manager roles, enable 2FA for all staff accounts, monitor orders for fraud and back up the database frequently.
Look for a provider who handles weekly updates, daily backups, uptime and malware monitoring, monthly reports and fast incident response, with clear responsibilities in writing.
| Task | Frequency |
|---|---|
| Update core, themes and plugins | Weekly |
| Check backups restore correctly | Monthly |
| Review admin users and remove old ones | Monthly |
| Scan for malware | Weekly, automated |
| Review login attempts and blocks | Monthly |
| Renew SSL and check HTTPS | Automated, verify monthly |
Give each person their own account with the lowest role they need: Editor for content writers, Shop Manager for store staff, Administrator only for those who manage the site. Turn on two-factor authentication for every admin, and remove accounts the day someone leaves. Shared passwords are one of the most common causes of breaches.
See web development for maintenance plans.
The core is well maintained. Most issues come from plugins, themes, passwords and hosting, which you can control.
It's recommended for most sites, along with a firewall and good hosting.
At least weekly, and immediately for security releases.
SSL encrypts traffic but doesn't fix vulnerable plugins or weak passwords.
It can reduce bot noise, but it isn't a substitute for strong passwords, 2FA and rate limiting.
Not always. Updates, strong passwords, 2FA, a firewall and backups cover most risks; paid tools add monitoring and support.

Signs your WordPress site is hacked and a step-by-step recovery plan: contain, change credentials, restore or clean, remove backdoors, update, request…

WordPress backup best practices: what to back up, the 3-2-1 rule, frequency, plugin and hosting backups, off-site storage, testing restores and a reco…

A practical website security checklist: HTTPS, updates, strong logins and 2FA, backups, firewalls, secure forms, hosting, monitoring and what to do if…
Sakr Web builds and grows websites, stores and apps: design, speed, security, SEO and ads.
Website, store, app, SEO or marketing: a free plan and quote within 24 hours.