Ban IP to Stop WordPress Comment Spam Forever
WordPress spam comments is a big problem, but how can we stop, ban , block spam comments before they hit our wordpress blogs. A simple plugin can ban IP addresses of spammers and significantly reduce spam comments on your blog.
WordPress Anti Spam Tools
WordPress Spam Blocking Plugins: Most wordpress blogs use an amazing anti-comment spam tool called Akismet, but it is smart at identifying spam comments and moving them to the Spam Comments folder (it has blocked over a million spam comments here and you can’t even think of turning Akismet off). But what if you have to manually fish out any valid comments among hundreds of spam comments?
WordPress Comment Moderation: If you navigate to the WordPress Admin > Settings > Discussion, you will find 2 options
1. Comment Moderation will hold a comment in the queue if it contains X (you decide, I keep it at 1) or more links. (A common characteristic of comment spam is a large number of hyperlinks.) So when a comment contains any of these words in its content, name, URL, e-mail, or IP, it will be held in the moderation queue. 2. Comment Blacklist – When a comment contains any of these words in its content, name, URL, e-mail, or IP, it will be marked as spam. You can read more about these WordPress spam combating options.
So you block IP addresses via the blacklist, it will move all such comments to the spam queue, but that still means work for bloggers to screen for valid comments (unless you prefer to click “Delete all Spam”, which will also delete any useful comments, and invite query from readers as to why you deleted their comments). Did you know many valid comments are often blocked by Akismet and affected commentators can request Akismet to despam your valid comments.
Of course you can edit your .htaccess file to block some IPs, but how many times can you keep doing that manually?
Ban Spam IP: Stop Comment Spam
Welcome to WP-Ban, a very powerful wordpress plugin which helps you easily ban users by IP, IP Range, host name and referrer url from visiting your WordPress’s blog and prevent spam from ever reaching your comments. It will display a custom ban message when the banned IP, IP range, host name or referrer url tries to visit your blog.
The Ban Stats can reveal valuable info about spam attempts -

Ever since I have enabled this plugin, my spam comments are nearly zero and I can now easily screen and approve any comment wrongly labelled as spam.
But there is a word of caution, do NOT block your own IP. Do NOT use wild cards to block a large number of IPs or domains carelessly or you could be blocking thousands of your own readers and search engine bots. If you simply block the IPs which occur too frequently in your spam comments, ban those IPs and see your spam reduce in minutes. Thanks to John Chow where I first saw it in action.
« Previous Post Next Post »



Thanks. I did read this in john chow blog
Here’s an example to illustrate why this is a bad idea.
A spammer has tried to post the exact same comment on my site over 20 times in the past 2 weeks. Different articles most of the time, and SpamKarma2 says that *the captcha was filled in”. Best part? Each comment was from a different IP address.
Many spammers use trojans to spread their garbage. By blocking those IPs, you’re blocking potential visitors as well.
The best solution is to use plugins like Akismet, SK2, Wp-Spamfree, etc. that analyze incoming information based on many criteria and automatically decide how to treat it. Then tweak as you go.
I only block IP addresses from which at least 10 definite spam comments come. That way I am sure I am not blocking my readers, and only a few most troublesome IPs are blocked. I let Akismet handle the rest.
Hi,
Sorry, but this is a truly terrible course of action to recommend. Spammers just don’t use IP’s that belong to them, so all you will block, at best, is compromised machines. Which means, if we are talking about Windows machines, an enormous number of them.
The only thing that I can think of that is a worse idea than IP banning is banning entire countries based on IP ranges.
Use Askimet, or Defensio, and if you are not happy with those, add recaptcha or similar.
They’ll do the trick.
This appears to be quite a handy plugin that many webmasters/blog owners should implement.