Gab Captcha 2 plugin for WordPress

Gab Captcha 2 banner

Gab Captcha 2 plugin for WordPress

GabSoftware proudly presents its captcha plugin for the comment section of WordPress blogs, Gab Captcha 2.

Gab Captcha 2 settings

Gab Captcha 2 settings

Gab Captcha 2 is an efficient and simple captcha plugin for WordPress comments.

It adds an easy turing test before each comment form. The turing test consist in typing the characters that appear emphasized and red in a text field. The plugin will add an entry in your WordPress administration area to let you configure some options.

Gab Captcha 2 currently comes in two languages: English (default) and French. You are welcome to propose your own translation or to update existing ones, especially the English one as I am not a native English speaker.

Important notes

  1. This plugin requires Javascript to be able to post a comment.
  2. This plugin can automatically approve valid comments depending on your settings.
  3. This plugin requires PHP 5 to function.
Gab Captcha 2 in action

Gab Captcha 2 in action


This section describes how to install the plugin and get it working.

1. Extract and upload the directory “gabcaptcha2” and all its content to your ‘/wp-content/plugins/’ directory
2. Activate the plugin through the ‘Plugins’ menu in WordPress

Optional but recommended :
3. Change the options to fit your needs in the ‘Settings > Gab Captcha 2’ menu in your WordPress administration area
4. If you don’t want to receive an email after each spam has been catches:
4.1. Go to the ‘Settings > Discussion’ menu
4.1.1. Tick the following checkboxes:
“E-mail me whenever > Anyone posts a comment”
“Before a comment appears > An administrator must always approve the comment”
“Before a comment appears > Comment author must have a previously approved comment”
4.1.2. Uncheck the following checkbox:
“E-mail me whenever > A comment is held for moderation”
4.2. Go to the ‘Settings > Gab Captcha 2’ menu
4.2.1 Choose ‘yes’ for ‘Automatically approve comments who passed the test’

You will now receive an email only after a valid comment has been posted.


To uninstall Gab Captcha, simple deactivate the plugin then remove the gabcaptch2 directory from your ‘/wp_content/plugins’ directory.

With Gab Captcha, spam should now be a thing of the past !

You can download Gab Captcha in the downloads section.

Frequently Asked Questions

Is Gab Captcha unbeatable by spambots?

Definitely not. But it stopped all my spam as of today (getting about 100 spams every single day).

Can I change some settings for Gab Captcha 2?

Yes. Go to the ‘Settings > Gab Captcha 2’ menu in your WordPress administration area.

59 Responses

  1. Taylor says:

    I just installed GC2. I notice that if a user enters the characters incorrectly, sends, then enters the characters properly, GC2 reports “You just said that.” on a page that has no links to return to the post. It also does not post the comment even though the characters used were correct.

  2. Thunacrab says:

    @ Taylor:

    I am having this problem too. I love this script otherwise. Hopefully the author will tweak the code to fix this. I’d hate for someone on my blog to write a really long comment then lose all their text because of this bug.

  3. @Taylor and Thunacrab:

    You are correct, it’s the WordPress duplicate comment checker who is responsible of this message. I will try to find a solution to this problem because you are right to say that it is not a desirable behavior. Maybe it’s just an option to turn off in WordPress. Or maybe it’s the behavior of GC2 that I’ll have to change: when you don’t enter the correct code, a comment is inserted to the database into the spam folder. Posting the same comment with the correct code will thus trigger the WordPress duplicate comment alert. A new version should be released soon to address this issue ๐Ÿ™‚

  4. Laura says:

    I tried to install on my new WP blog today, receive the following fatal error when I try to activate it.

    Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or ‘}’ in wp-content/plugins/gab-captcha-2/gabcaptcha2.php on line 86 …. ????

  5. @Laura:

    I don’t have this error, neither the other two persons who posted a comment. That must be a transfer error. Can you try to re-upload the latest version?

    Also, the plugin uses a class, which requires PHP 5. Do you have a PHP4 server ? If yes, see if you can activate PHP 5.

  6. @Taylor and Thunacrab:

    Version 1.0.5 should correct the problem. Please note that the comments which didn’t passed the test are no longer stored in the spam folder: they are deleted.

    Also note that for if you provide a valid solution too quickly after your first failure, you will have a WordPress message “you are posting too quickly”. That’s the WordPress anti-flood system. I will address this issue on the next version.

  7. Gilbert says:

    How do I translate your Captcha to German?
    What files do I need to change? And what name to those need?


    • Hi Gilbert, thanks for your proposition!

      To translate Gab Captcha 2, proceed as follow:

      Download Poedit (
      Install it
      Fill in your name, email address, etc. This will define you as the German translator

      Copy the file lang/default.po under the name “gabcaptcha2-de.po”
      Open the file “gabcaptcha2-de.po” with Poedit (using “File>open”)
      Go to “Catalog>Settings” and change “Language” to “German”. Leave “Country” empty. You can change “Team” and “Team’s email address” to your team’s informations.
      Translate and save (“Save catalog”)
      Send me the file “gabcaptcha2-de.po” and “” if there’s one

      I will then include your translation in the next version of Gab Captcha 2 very soon.

  8. Thunacrab says:


    The update fixed the problem thanks!

    I have one little idea/recommendation for your plugin though… Upon failing the captcha, the page reloads at the top, unlike when you pass the captcha, it auto scrolls down to your comment at the bottom. I think it would be a good idea to scroll down to the “you fail” text if the captcha is failed, just in case someone posts, then navigates away from the page thinking their comment got posted.

    Just an idea. Love the plugin, thanks.

  9. Thunacrab says:


    I just updated, and tried an intentional failure… Everything is working perfectly.

    Thanks for the update!

  10. Nice! You are welcome ๐Ÿ˜‰

  11. Thunacrab says:

    By the way, I can’t tell you how great this captcha has been for simplifying comment moderation. I used to approve comments individually so my blog doesn’t fill up with a bunch of spam, but that method is tedious and bad for the people who actually make real comments… people expect to see their post right after they make it.

    Not many people read my blog, it is just a little personal place to post my thought, but I was still getting at least ten spams a day.

    Since GabCaptcha, not one spam has slipped though.

    Great job man. I’ll recommend this to anyone with spam problems. I tried about five other captchas before settling on yours. In my opinion, it is the best lightweight spam solution currently out.

  12. I know what you mean, I was approving comments manually too before I developed Gab Captcha 2, and that was a little frustrating for the users and time-consuming for me. I get about 100 spams every single day so that was nice not to have to check which comment is from a real user.

    The spam comments that I receive are quite cleverly designed, they congratulate the blog owner so that the owner may not recognize the spam, but a link to a commercial website (generally not legal) was always included. Sometimes it was not possible to guess with the link alone. So I saved myself from a lot of hassles with Gab Captcha 2 ๐Ÿ™‚

  13. Thunacrab says:

    Haha, yeah! Clever and congratulatory spam is almost like a horoscope: Generalized, and just vague enough to be universally applicable to most blog content.

  14. @Thunacrab: Understood and done ๐Ÿ˜‰

  15. billy says:


    First, thank you for sharing your wonderful code. It has helped very much with spam. However, my bots were learning to get by it, so I thought I would up it to 8 characters. When I did, it displays eight characters in red, but I can still only type in four (The field is limited to four), therefore always fails. Any ideas on what I may be doing wrong?

    Thanks; Billy

  16. Allison says:

    I have installed and activated your plugin but it doesn’t show up on the comments. Did I miss something?

  17. Hans says:

    I am unable to uncheck the: Automatically approve comments who passed the test.
    When I uncheck it, at click save, the box stay checked.
    Any idea why?

  18. Hi Hans,

    I confirm this behavior in my installation too. Looks like you found a bug ๐Ÿ™‚

    I will fix it for the next version, that should be out tomorrow.

    Thank you for your report and your patience.


    Gabriel Hautclocq

  19. Rob says:

    I found your captcha on a different website and couldn’t help myself from cracking it. D: It’s a nice script for sure, but definitely easy to break as well. For any blog that’s using it, I can set up a userstyle with stylish and a script with greasemonkey to hide that field as well as have it fill itself in automatically.

    That said, I’m sure it stops quite a bit of spam, since you do need to do a small workaround. Thanks for the fun for the afternoon. ๐Ÿ˜€ Gabriel, If you’re interested in the small script I use to fill the field, let me know. I didn’t even need the source code for it. D:

  20. Hi Rob,

    Sure, please send !

  21. Rob says:

    It’s not anything I’ve ever done before, but I’ve been told I’ve got the right mind for programming. I saw it and thought “Well this should be fun!” and went ahead and did it. Took me a while, as I’ve never really used all that much javascript before and didn’t know what anything was. That said, it made a great break from work!

  22. Now you can try to break the CSS and CSS 3 security modes ๐Ÿ˜‰

  23. Rob says:

    I’ll have to download it and give it a whirl!

  24. Alan says:


    The plugin works great, but on my blog ( it’s inserted in an existing field.
    How can I change the place where it’s displayed ?

  25. Hi Alan,
    It is displaying as it should for me, using Opera. Could you send a link to the screenshot of the problem?

  26. Alan says:

    here is a screen capture on Firefox (the same on Safari)

  27. Okay I understand the problem. The way your theme has been conceived, each of your field is inside a TABLE TD element. The captcha insert itself right after the url field, so in the same TD element as the url field…

    Unfortunately there is no way for GabCaptcha to know where to insert itself precisely.

    If you can, try to edit your theme comment section so that it does not use TABLE and TD elements.

    I will try to find another way to insert the captcha to fit themes like yours.



  28. Robi says:

    Support this captcha plugin and register/login form or only comments?

  29. Chris says:

    I noticed when looking at the source for it, you’re using both <strong> and <span> for it. I feel you’d be better off if you just use one type, and change the font-size/color based on the class. Otherwise someone trying to spam could just look for the contents of the <strong> tags. Not sure if you already handled this somehow, but figured I’d put it out there.

    • Hi Chris,

      Yes, you are right, but that is also true for classes. I think that a spam bot programmed to crack GabCaptcha could do it rather easily using some simple regular expressions. As long as there is a pattern to find, regular expressions can solve it.

      However, you can check in the options, there are 3 levels of security, and the strongest one only uses CSS.

  30. Alex says:

    Just installed it on my blog (WordPress v3.3) but I do not get a Settings option for in the Plugins section for Gab Captcha 2.

    And the plugin is not working. Any advice? (Yes, it is activated)

  31. Jonne Backhaus says:

    The gab chaptha plugin dows not show up in the comments form after the newest update, it has been working fine until I update to it.

  32. Carol says:

    I can’t get this to work in IE 8, which is a large part of our target audience. The code and input box won’t appear. It does work in our other browsers. The error is “no such interface supported”. Does anyone else have this issue – and is there a fix for this? Thank you in advance!

    • Hi Carol,

      I confirm the problem. It must have appeared with the latest release of Gab Captcha. I need to investigate, and I will try to fix it today. Thank you for your patience and for reporting this!

  33. kobe vii says:

    this is an interesting plugin i found today, good for bloggers

  34. BartC says:

    Hi Gabriel,

    I am running WP 3.2.1 and the theme is Techozoic Fluid 1.9.4

    I recently upgraded from an earlier version of Gab Captcha to v 1.0.20

    The earlier version worked just fine. All failed comments were sent to the trash folder. However, after the upgrade, and within moments, I found that had about 100 comments pending approval. The majority were spam. I can not tell if they are failed captcha or how they came to be in my pending approval queue.

    I have played with the Gab Captcha settings, and cleared the cache. I have also upped the required letters to 7 with a total of 30 characters.

    Nothing seems to help. Any suggestions?

    site: (link removed)


    • BartC says:

      Can I down grade to the previous version… How do I do that?

      This issues is making if very difficult to respond to legitimate comments. It is like trying to find a needle in a hey stack.


    • Hi BartC,

      Is “Automatically approve comments who passed the test” checked in Gab Captcha settings?

      Also, do you changed any settings in your Settings>Discussion page ( /wp-admin/options-discussion.php )?

      Sorry for the trouble and thank you for using Gab Captcha 2.

      • BartC says:

        Automatically approve comments who passed the test: NOT checked
        Insert blocked comments in database: NOT checked

        As for the Discussions page:
        top three defaults are ON
        the rest have not changed.

        I can send screen shots if you like.

        To be clear, the spam is not posted to the public site, it ends up in the queue for approval. Where as before it went straight to the trash folder.

        For example, this morning I had just over 200 comments, but only two were real. With the previous version of GC2 those 198 would have gone straight to the trash.


  35. BartC says:

    So I have been playing around with various settings. And I enabled:

    Insert blocked comments in database.

    Iโ€™m not sure why but now the failed comments go directly to the trash folder, as they did before. But, perhaps the label for this feature needs re-thinking.

    If the check is present or if the check is removed the comment still goes into the database. In one case it is marked as trash and in the other case it is marked as pending approval. But in both cases it is in the database.

    Iโ€™m not sure if I inadvertently deselected this when I updated or if its function changed. But, I think all is well now.

    Thanks for your kind support and help on this.

    • Hi BartC,

      I think you are right, I will have to re-think the labels to clarify what they do exactly.

      I suppose that you want the spam to be trashed and also you still want to approve manually each legit comment. That may sound silly, but I didn’t think about that specific case ๐Ÿ™‚

      The “Automatically approve comments who passed the testโ€ checkbox will actually define whether spam comments go to the Trash or to the Waiting for approval section.

      Anyway, it’s good to hear that it’s fixed for you now ๐Ÿ™‚

      • BartC says:

        I suppose that you want the spam to be trashed and also you still want to approve manually each legit comment. That may sound silly, but I didnโ€™t think about that specific case ๐Ÿ™‚

        Yes, that is exactly what I want it to do. Perhaps the way to approach this is to have settings that fork to โ€˜Failed captchaโ€™ and โ€˜Passed captchaโ€™

        In my case, I want all passed captcha to be held for approval, and I want all failed captcha to go to the comments trash folder. This way I can handle the passed ones without a lot of noise from the spam, and I can review the failed/spam ones to see who is spamming me, and perhaps see that rare one that failed but is a real comment.

        So in my case they both (passed and failed) are added to the database, but in different places.

        I think having two sets of settings based on pass/fail is the clearest way to go.


  36. BuckoA51 says:

    Gab Captcha 2 seems to be incompatible with the theme I’m using (Easel by Philip M. Hofer (Frumph) ), can’t get it to appear on my pages at all, I did try legacy theme mode too ๐Ÿ™

  37. Stef Gonzaga says:


    I’m having a problem with the plug-in. On Chrome, the captcha is positioned where it should be. But when on Safari (and possibly other browsers), it overlaps the other comment fields.

    Here’s a screenshot:

    I hope you’ll be able to provide a fix for this. Thanks!

    This is my website:

  38. April says:

    Hello there, I just installed your plugin, but for some reason, it puts the Captcha BELOW the “post comment” button. How can I move it above the button? Thanks!

  39. Mariam says:

    I also have a problem with the position of the Captcha. It overlaps the other comment fields. I’m using Mozilla Firefox, on IE it is even worse.
    How can I solve the problem? Thanks!

  40. Alveena says:

    First of all thank you for posting. The plugin I am looking for is the one you are having on your website. Could you please let me know what plugin are you using.???

Leave a Reply

Your email address will not be published. Required fields are marked *


This site uses Akismet to reduce spam. Learn how your comment data is processed.