• X

    How to avoid Spam comments on WordPress using .htaccess method

    By in Uncategorized

    Bluehost hosting

    How to avoid Spam comments on WordPress using .htaccess method

    These days I’m seeing lots of wordpress spam comments.The simplest way to avoid spammer is by using Akismet wordpress pluginwordpress logo thumb10

    You can get the Akismet WordPress plugin from here.

    Though at times if you will see your comment spam page, you might find few IP’s are constantly sending comment spam. The easiest way to get rid of these spam is by blocking their IP address using .htaccess method.

    I highly recommend keeping a backup of your .htaccess file before editing it.

    If you don’t know how to edit your .htaccess file, read my previous post on

    how to edit wordpress .htaccess   file

    Here is the code that you need to enter in your .htaccess file, and upload it.

    <Limit GET POST>
    order allow,deny
    deny from
    allow from all

    You can always enter more IP’s by adding one more line

    deny from xx.xxx.xxx.xxx

    You can get the IP of the spammer in your spam comment page, under wordpress dashboard

    wordpress spam comment thumb

    I find this way to be the best way to fight against the lots of spam from bots.

    If you are not familiar with wordpress, do read my previous tutorial on

    Step by step guide to Install self hosted #Wordpress blog

    $49 worth WordPress Guide

    Discover more awesome articles

    Article by

    Harsh has written 1129 articles.

    If you like This post, you can follow ShoutMeLoud on Twitter. Subscribe to Blogging tips via RSS or EMAIL to receive instant updates.

    { 1 comment… read it below or add one }


    I did this before. When some bad guy kept spamming and also used abusive language.


    Leave a Comment

    Previous post:

    Next post: