WordPress Security

How to Judge Whether a WordPress Plugin Is Safe

Plugins are how most WordPress sites get compromised. How to assess one before installing it, what to monitor afterwards, and when to remove it.

By 6 min read
Shield with a tick mark over three stacked layers

WordPress core is audited, patched quickly and updates itself for security releases. The plugins around it are written by tens of thousands of different people to wildly varying standards, and that's where the risk lives.

You can't avoid plugins, and you shouldn't try. What you can do is choose them deliberately. Here's what to look at.

Why plugins are the weak point

A plugin runs with the same privileges as WordPress itself. It can read and write your database, read and write files, make outbound requests, and add code that runs on every page view.

Most plugin vulnerabilities fall into a small set of categories: missing capability checks on an action, missing nonce verification allowing cross-site request forgery, unescaped output producing cross-site scripting, unsanitised input reaching a database query, and arbitrary file upload.

None of these are exotic. They're the consequence of plugins being written quickly, often by people whose main expertise isn't security, and then not being maintained as standards improved.

Before installing: the checks that matter

  • When was it last updated? A plugin untouched for two years is a plugin nobody is patching. This is the single most informative signal.
  • Does it declare support for the current WordPress version?
  • How many active installations? Widely used plugins get more scrutiny and faster fixes. Very low install counts aren't disqualifying, but they mean fewer eyes.
  • Is the support forum answered? Read the last dozen threads. A developer engaging with problems is a developer who'll respond to a vulnerability report.
  • Is there a changelog, and does it read like real maintenance rather than version bumps?
  • Does the developer have other plugins, and are those maintained too?
  • Check the plugin's history in the public vulnerability databases. A past vulnerability isn't disqualifying — everyone has them — but a pattern of them, or one that took months to fix, is informative.

Signals that should stop you

  • Distributed outside the official repository or the developer's own site, especially anything labelled free that is normally paid.
  • Nulled or cracked premium plugins. These very frequently ship with a backdoor, because the backdoor is the reason someone bothered to distribute them.
  • A plugin that asks for far more access than its purpose requires.
  • Obfuscated or encoded code in a plugin that has no reason for it.
  • A licence check that fails closed and disables your site, or that phones home with more than a licence key.
  • Abandoned plugins that have been taken over by a new owner — ownership transfers have been used to push malicious updates to existing users.

Reduce the surface

The safest plugin is one you didn't install. Before adding another, check whether the theme, WordPress core, or a plugin you already have does the job.

  • Delete plugins you aren't using. Deactivated is not removed — the code is still on disk and still unpatched.
  • Prefer one plugin doing one thing over a suite where you need two of forty features.
  • Replace trivial plugins with a few lines in a site-specific plugin: a tracking script, a dashboard widget removed, an excerpt length changed.
  • Don't keep two plugins that do the same job. They conflict as well as duplicate.
  • Review the list quarterly. Plugin lists grow and nobody removes anything without a prompt.

Themes carry the same risk

Everything on this page applies to themes, which get far less scrutiny because people think of them as design rather than code. A theme is PHP running on every request, with the same privileges a plugin has.

  • Multipurpose themes bundling a dozen premium plugins are a particular problem: the bundled copies update on the theme author's schedule, not the plugin author's, so a patched vulnerability can sit unfixed in your site for months.
  • Check whether a theme bundles plugins at all, and whether it delivers their updates promptly.
  • Delete unused themes. An inactive theme is still unpatched code on disk, and vulnerabilities in inactive themes have been exploited.
  • Keep one default WordPress theme installed and updated, as a fallback for debugging.
  • Never use a nulled premium theme, for exactly the reasons a nulled plugin is a bad idea.

Staying informed after installing

The plugin that's safe today may have a disclosed vulnerability next month. What matters is how quickly you hear about it.

Use a service or plugin that checks your installed versions against known vulnerability databases and alerts you. This is the difference between patching within hours of disclosure and finding out when the site is defaced.

Public vulnerability disclosure is a race: once a fix is published, the vulnerability is public, and automated scanning for unpatched sites begins almost immediately. The window between disclosure and exploitation is frequently measured in days.

Updating without breaking things

  • Security updates go on immediately. The risk of a broken layout is smaller than the risk of an exploited site.
  • Other updates on a schedule, tested on staging first, with a backup taken beforehand.
  • Read changelogs for major version bumps — those are where breaking changes live.
  • Update one significant plugin at a time on a complex site, so a breakage is attributable.
  • Keep a staging environment. Sites without one either update recklessly or don't update at all, and both end badly.

When a plugin you use is vulnerable

If a fix exists, apply it now. That's the whole answer in most cases.

  • If no fix exists yet, assess whether the vulnerable feature is one you use, and whether you can disable it.
  • If the plugin is abandoned and a vulnerability is disclosed, remove it. There is no fix coming.
  • Check whether you were already exploited: unexpected admin accounts, modified files, PHP in the uploads directory, unrecognised scheduled tasks.
  • A web application firewall at your host or CDN can sometimes block exploitation of a known vulnerability before a patch exists, which buys time but isn't a substitute.

Premium doesn't mean secure

Paying for a plugin buys you support and usually more active development. It doesn't buy you a security guarantee — plenty of serious vulnerabilities have been in widely used commercial plugins.

Premium plugins also often update outside the WordPress repository, which means they don't always appear in the normal updates screen and can silently fall behind. Check that your licence is active and that updates are actually arriving.

An expired licence that stops delivering security updates while the plugin keeps running is a common and dangerous state.

Frequently asked questions

Are plugins from the WordPress repository safe?

Safer, not safe. Repository plugins are reviewed at submission and can be removed if a serious issue is found, which is real protection. But the review isn't a full security audit, and a plugin that was fine in 2019 may be unmaintained now. The last-updated date matters more than where it came from.

How many plugins is safe to have?

There's no number. Twenty actively maintained plugins are safer than five abandoned ones. What matters is that each is maintained, that you actually use it, and that you hear about disclosed vulnerabilities quickly. Delete what you don't use — deactivated plugins are still unpatched code on disk.

Why shouldn't I use nulled premium plugins?

Because the backdoor is usually the point. Someone went to the trouble of cracking and distributing it for a reason, and that reason is access to the sites that install it. You also get no security updates, which on a plugin handling payments or customer data is indefensible.

How do I know if a plugin I use has a vulnerability?

Use a service or plugin that checks your installed versions against known vulnerability databases and alerts you. Disclosure makes the vulnerability public, and automated scanning for unpatched sites starts within days — so the gap between disclosure and your patch is the whole risk.

What should I do if a plugin I need is abandoned?

Start looking for a replacement now rather than when a vulnerability is disclosed, because at that point there is no fix coming. In the meantime, check whether the functionality could be replaced by a few lines of your own code, which is often the case for simple plugins.

Topics

  • WordPress plugin security
  • plugin vulnerabilities
  • safe WordPress plugins
  • WordPress exploits