How to Add reCAPTCHA to WordPress Comment
How to Add reCAPTCHA to WordPress Comment. Spam comments on WordPress websites are out of control. Instead of blocking comments, you can add captchas to the comment form to practically eliminate spam.
Would you like to add reCAPTCHA to your WordPress comment form? In this tutorial, we will show you how to easily add reCAPTCHA in the comment form of your WordPress website.
What is Google ReCAPTCHA?
Comment spam is a problem on many WordPress websites. Akismet, a popular spam filtering service for WordPress, blocks approximately 7.5 million spam comments per hour. ReCAPTCHA is one of the best ways to combat this.
ReCAPTCHA is an innovative form of CAPTCHA that can differentiate between robots and human users. CAPTCHA stands for ‘Fully Automatic Public Turing Test to Separate Computers and Humans.’
Google acquired Captcha technology in 2009 and later rebranded it as reCAPTCHA. They also make it easier for human users to pass tests.
To pass the test, users need to click on a checkbox that indicates that they are not robots. They will give immediately or be presented with multiple images where they need to click on similar objects.
Google has made reCAPTCHA publicly available, so that website owners can use it on contact forms, login pages, and comment forms to reduce spam.
WordPress Comment Form is elementary to set up and add.
With that, let’s see how to easily add reCAPTCHA to the WordPress comment form with step-by-step instructions.
Installing a WordPress reCAPTCHA plugin
First, you need to install and activate the simple Google reCAPTCHA plugin. You can see our step-by-step guide on installing the WordPress plugin for detailed instructions.
Upon activation, you will be automatically taken to Settings »Google reCAPTCHA to configure the plugin settings.
The plugin will ask you to provide the Google reCAPTCHA API keys. You can generate these keys for free from the official reCAPTCHA website by clicking on the ‘Register Your Domain’ link at the top of the screen.
Register your website to get the reCAPTCHA API keys
The ‘Register your domain’ link will take you to the Google reCAPTCHA website, where you can register your site to work with reCAPTCHA.
You will be asked to sign in with your Google Account. After that, you will see the “Register New Site” page, where you must provide basic information to register your site.
First, you need to type the name of your website or any representation of your choice in the label field. This will help you to identify your site in the future quickly.
Next, you need to select the reCAPTCHA V2 radio button.
This will open up three new options. Since you want to add the reCAPTCHA checkbox to your site, you must select the “I’m not a robot” checkbox.
The domain text box allows you to add the domain name of your website where you would like to add the reCAPTCHA checkbox.
You can add multiple domains or subdomains by clicking on the plus (+) icon. This will allow you to use duplicate API keys on different websites.
# 1: Add the domain and email to the reCAPTCHA site.
Under Owners, Google will already add your email address. You can add another email if you wish.
After that, you must accept the terms of service to use Google reCAPTCHA on your site.
Also, select the ‘Send alerts to owners’ checkbox to allow Google to send you emails if they detect an incorrect configuration or suspicious activity.
# 2: Submit and register your WordPress site.
After filling out the form, you can click the Submit button to register your site.
Google reCAPTCHA will show you a success message with the site’s secret keys on this page.
# 3: Copy Site & Secret Keys
You can now use these API keys in the plugin settings on your website.
Adding reCAPTCHA to the WordPress comment form
From the left sidebar of your website’s admin panel, go back to Settings »Google reCAPTCHA.
It would help if you pasted the site and secret keys on the settings page.
The plugin will include the WordPress comment form and the registration form, reset the password form, the new password form, and the reCAPTCHA authentication in the login form.
If you wish, you can disable reCAPTCHA on the login form by clicking on the checkbox.
Once done, click the “Save Changes” button to store API keys and enable reCAPTCHA.
Congratulations, you have successfully added reCAPTCHA to your WordPress comment form. Now you can check the comments section of your blog posts to confirm that it is working correctly.
Note: The reCAPTCHA checkbox will only be shown to users who log out. To preview reCAPTCHA, you’ll need to log out of WordPress or open your website in your browser’s privacy window.
We hope this tutorial helps you learn how to add reCAPTCHA to your website’s WordPress comment form.
You can also learn how to slow down the loading of comments in WordPress to improve your page load time or check out our must-have plugins to enhance your site.