Stopping spam comments in WordPress

If your blog has comments open, sooner or later it fills up with offers for watches, links to doubtful sites and sentences that make no sense. Whoever wrote them is not a person: it is a program trying to publish its link on thousands of sites. There are four layers that stop it, and it pays to use more than one. Start with the one that costs nothing.

The layers, from simplest to strongest

1 Ask more of the commenter. In Settings, Discussion, tick “Comment author must fill out name and email” and, if your site can live with it, “Users must be registered and logged in to comment”. Each requirement shuts out a share of the programs.
2 Approve the first comment by hand. On the same page, tick “Comment must be manually approved”, or at least “Comment author must have a previously approved comment”. Nothing appears on the site without passing through you.
3 Hold anything that carries links. Still in Discussion, moderation takes a maximum number of links per comment and a list of words: whatever contains them is held. The disallowed list sends comments straight to the bin, without even reaching moderation.
4 Close comments on old posts. The programs love forgotten articles. Discussion has an option to close comments after a length of time that you choose.
5 Switch on Akismet. It usually ships with WordPress, switched off. It is an outside service that analyses each comment and sorts out the spam by itself. It needs a key, and the terms of use depend on the kind of site: read them on the service’s own page before you activate it.
6 Put a challenge on the form. A captcha plugin, or one that hides a field only programs fill in, stops much of the rest. See putting a captcha on the WordPress login, which works in a similar way.

Clearing what is already there

In the WordPress dashboard, under Comments, the Spam tab holds what was caught: you can empty it in one go. Pending comments can be approved, rejected or deleted in bulk. The more that pile up, the more the database grows for no reason.

You want to Do this
Stop comments across the whole site In Settings, Discussion, untick allowing comments on new posts. Existing posts keep their own setting.
Stop them on posts that already exist In the posts list, select them, choose Edit in the bulk actions and set comments to not allowed.
Stop getting an e-mail for every comment In Discussion, untick the e-mail notifications.
Block spam through pingbacks and trackbacks In Discussion, untick notifications from other blogs.
Do not mix this up with contact-form spam. They are different paths: the form sends you an e-mail, the comment is published on the site. Each has its own defence. If what bothers you is messages reaching the mailbox, see stopping spam reaching your mailbox.
Do not delete everything in a hurry. Now and then a genuine comment lands in Spam by mistake. Run your eye down the list before you empty it. And if you never wanted comments, the cleanest answer is to switch them off.

Is your site getting slow with thousands of comments to clear? Tell us the address and we will look at what the server shows.

Open a support ticket

SEE ALSO

WordPress hosting

Frequently asked questions

Support Policy

RECOMMENDED PRODUCT

WordPress hosting

One-click install, updates handled, and speed that holds up. from $6.59/mo (3-year plan, with coupon)

See plans
  • 0 Users Found This Useful
Was this answer helpful?