How to add reCAPTCHA in WordPress forms - step by step

A reCAPTCHA is used to keep your page from spam when you have forms. As you well know, there are programs that surf the Internet using robots looking for forms that fill in to send deceptive advertisements with possible spam, which damages a page (that's why WordPress even allows you to configure the comment settings and avoid spam).

Fortunately, in turn, Google has created a tool to be able to identify them through the use of reCAPTCHA. These are pictures you need to read. Robots can't read pictures or click a box, for example. Let's see how to add a reCAPTCHA to our modules WordPress.




How to create a contact form in a few steps

To create a contact form you need to install the plugin. To do this, go to the Plugins section you have in the left menu of your WordPress.

How to add reCAPTCHA in WordPress forms - step by step

From the search field you have at the top right, write Contact form. Choose one and click Install. It takes a few seconds for the download. Then click Activate.

In case you haven't activated it at the moment, go to Plugin> Installed, look for the contact form and activate it. When you do, it should give you one shortcode.

Now, you need to create a contact page from the Page> Create New Entry section. Copy and paste the shortcode where you want your page form to appear and voila.

Remember that there are a lot more plugins that allow you to add a lot of elements, so doesn't it hurt to research which are the best page layout plugins?

How to add a reCAPTCHA in WordPress forms step by step

To add a reCAPTCHA in WordPress forms the reCAPTCHA service must be activated from the Google website. From there, click on the blue Get reCAPTCHA button you have in the top right corner.




Next, fill in the form fields with a name so that you can identify the reCAPTCHA you are about to create and the domain of the webpage you want to add it to. Finally click on Register.

Then Google will show you another page where it explains how to integrate the created reCAPTCHA. The only thing you will need are the values ​​and keys of: Site key (site key) and Secret key (secret key).

How to add reCAPTCHA in WordPress forms - step by step

Open another tab with your website's WordPress. Enter the Contacts> Integration section, from the menu on the left. Now you need to click on Configure Keys in reCAPTCHA.

On the next tab, enter the site key and secret key values ​​we saw earlier. You can copy and paste them to avoid mistakes. Click Save to close and keep the changes. Now you just need to add the reCAPTCHA field to your form. To do this, enter the Form from the left.

You need to place it before the submit button. Add the following code to your form before and after the reCAPTCHA from the button you have at the top of the editions:


& nbsp;

Remaining as follows:

& nbsp;

[summarizing]


& nbsp;

Save your changes and verify that everything is working correctly.

To do this, you can access your website from an incognito window. From there, position yourself on the form page and make sure it works as it should. If you hit submit without clicking reCAPTCHA and you get an error, it's because it's working correctly.


Time you have a form created in a practical and spam-free way. Other than that, you should learn how to put the cookie notice or policies on your website, because that way it will look much more professional.

If you have any questions about how to add reCAPTCHA in WordPress forms, you can leave it in the comments so we can help you.

add a comment of How to add reCAPTCHA in WordPress forms - step by step
Comment sent successfully! We will review it in the next few hours.