WordPress powers a large share of the web, which makes it a frequent target for automated attacks. That does not mean WordPress is insecure. Most compromised sites are breached through weak passwords, outdated plugins or careless hosting, not flaws in WordPress core. Good wordpress security is mostly about discipline: reducing the ways in, keeping software current, and being ready to recover quickly. Here is how we approach it for business websites.
Start with how attacks actually happen
It helps to know what you are defending against. Attacks on typical business sites are rarely personal. They are automated bots scanning thousands of sites for known weaknesses. The common entry points are:
- Vulnerable plugins and themes that have a published security issue and have not been updated.
- Stolen or guessed passwords, especially for administrator accounts with simple or reused passwords.
- Nulled (pirated) premium plugins, which frequently include hidden malicious code.
- Weak hosting isolation, where one compromised site on a shared account infects others.
- Abandoned plugins that no longer receive security fixes at all.
Each best practice below closes off one or more of these doors.
Layer one: who can get in
Access control is the cheapest and most effective security measure you have.
- Give every person their own account. Shared logins make it impossible to know who did what, and impossible to revoke access cleanly when someone leaves.
- Use the lowest role that works. Content writers rarely need to be Administrators; Editor or Author is usually enough.
- Require strong, unique passwords stored in a password manager.
- Turn on two-factor authentication for every account with administrative access. Several reputable security plugins offer this.
- Limit login attempts so bots cannot guess passwords endlessly.
- Review users monthly and remove anyone who no longer needs access, including former agencies and freelancers.
Layer two: the software you run
Every plugin you install is code from a third party running with full access to your site. Treat that decision seriously.
- Install fewer plugins. Fewer plugins means a smaller attack surface and fewer updates to manage.
- Choose actively maintained plugins with recent updates, a responsive developer and a solid reputation.
- Never use nulled software. If a premium plugin is worth using, it is worth licensing properly.
- Keep everything updated, including themes you are not using. Better still, delete inactive themes and plugins entirely.
- Disable file editing in the dashboard by setting the DISALLOW_FILE_EDIT constant in wp-config.php, so an attacker who gains admin access cannot easily edit PHP files through the browser.
Layer three: the server and hosting
Your hosting environment does a lot of security work you never see. Its quality matters.
| Hosting factor | What good looks like | What to avoid |
|---|---|---|
| PHP version | A currently supported release | Versions that no longer receive security fixes |
| Site isolation | Each site separated from others on the account | Many sites sharing one user and file system |
| HTTPS | Valid SSL certificate, renewed automatically | Mixed content or expired certificates |
| Firewall | Server-level or network-level filtering of malicious traffic | No filtering at all |
| Backups | Automatic, off-server, with easy restore | Backups stored only on the same server |
| Support | Staff who understand WordPress and respond to incidents | Generic support that cannot help with a hacked site |
A web application firewall, whether provided by your host, a CDN or a security plugin, filters many common attack patterns before they reach WordPress. It is not a substitute for updates, but it buys time when a new vulnerability is disclosed.
Layer four: watching for trouble
Prevention will never be perfect, so you need to notice problems early.
- File integrity monitoring alerts you when core files or plugin files change unexpectedly.
- Uptime monitoring tells you when the site goes down, which is sometimes the first sign of a compromise.
- Activity logs record logins, content changes and plugin installs so you can reconstruct what happened.
- Google Search Console notifies you if Google detects malware or hacked content on your site.
Read alerts when they arrive. A monitoring tool that emails an inbox nobody checks provides no protection.
Layer five: recovery
Assume that at some point something will go wrong, and decide in advance what you will do.
A simple incident plan
- Contain it. Put the site into maintenance mode or take it offline if it is serving malware or spam to visitors.
- Change credentials. Reset passwords for WordPress admins, hosting, FTP/SFTP and the database. Update the security keys in wp-config.php to force everyone to log in again.
- Find the entry point. Check logs and recently updated or installed plugins. Restoring a backup without fixing the cause usually leads to reinfection.
- Clean or restore. Restore a known-clean backup or have a specialist clean the files and database.
- Request review. If search engines flagged the site, request a review in Search Console after cleanup.
- Write down what happened and what you changed, so the same gap is not left open again.
Security and custom code
If your site includes custom themes or plugins, the code itself needs to follow WordPress security conventions: sanitizing input, escaping output, checking user capabilities and using nonces on forms and actions. These are standard practices in professional WordPress development, and they matter just as much as plugin updates. A lean custom theme often has a smaller attack surface than a heavy multipurpose theme, one of the trade-offs we cover in our comparison of custom WordPress themes and page builders.
A quick self-assessment
Answer these honestly. Every “no” is a task for this week:
- Does every admin use two-factor authentication?
- Are all plugins and themes updated and actively maintained?
- Do you have an off-server backup that you have tested restoring?
- Would you know within a day if your site were compromised?
- Do you know who to call if it were?
Getting help with WordPress security
SiteWright Technologies builds and maintains WordPress sites with security designed in from the start: clean custom code, careful plugin choices, hardened configuration and a clear maintenance routine. If you want an expert review of your current setup, explore our WordPress development services or contact us to arrange an audit.


