Preventing Blog Spam

Update: This tutorial is now superceded by A Comprehensive Guide to Protecting Your Blog from Spam.

Comment spam is something every blogger is really really afraid of. Over the past two years that I have been using WordPress this is one problem that I have faced on and off.
I realized that the amount of spam I was receiving was is direct relation to my popularity. (and I wasn’t that know then)

After a lot of experimenting, I have finalized settled down on the following. I’m pretty much spam free for now.


Firstly, get Bad Behavior installed. Bad Behavior blocks spam by checking Referer and a lot of other things the moment it touches your site. It runs silently in the background protecting you. Optionally, you can add my Bad Behavior Stats Plugin to display the number of blocked attempts on your blog.

Next, get hold of Spam Karma 2. Spam Karma is a comment spam protector. It provides many checks and drastically reduces the amount of comment, trackback and pingback spam. Optionally, add Spam Karma 2 Stats.

With just these two plugins installed I had almost zero spam on my site. However, I recommend a few additional things you can do.

Get hold of Moderate Plugin for SK2 and follow the instructions for installing it. This plugin will ensure that new posters will land into moderation for your approval. So even if a person gets through Bad Behavior and Spam Karma 2, you still choose whether you want to approve this comment or not. Believe, I’ve used it many times!

Also, to reduce email spam do not have any mailto: links on your site. Instead make use of contact forms or email plugins like my Transpose Email plugin to protect your email from harvesters.
Two popular contact forms for WordPress are PXS Mail and WP-Contact Form.

Yet another step to prevent bad bots and spam is to use your .htaccess file to block them. Read Blocking bad bots and site rippers (aka offline browsers). Here you will find a nice long list of what you will need to enter into your .htaccess to block the bots and spam.

Additional resources worth checking are:

I’m pretty much spam free today. So how about you?

(Visited 173 times, 1 visits today)

4 thoughts on “Preventing Blog Spam”

  1. Welcome Vamsi.

    I updated the post to add protection from bad bots and site rippers.

    Will be updating it still further or probably dedicate a page to it. Let’s see….

Comments are closed.