help center

On this page

Block spam messages from forms

Last Update: January 28, 2024

Forms are a great way to collect vital information from your visitors. However, one downside is spammers submitting bogus information, sometimes containing malicious code. 

To help screen for these spammers, Elementor forms now lets web creators integrate Akismet anti-spam filter into their forms.

Note
You must have an Akismet account in order to use the anti-spam filter. You can find more details about Akismet at their website.

Add an anti-spam filter to your forms

  1. Download and install the Akismet plugin. For more details, see Install WordPress plugins.
  2. Create an Akismet account. For more details, go to the Akismet site (external site). 

After you register with Akismet, you’ll be given an API key.

  1. Copy your Akismet API key.
  2. Open WP Admin.
  3. Go to Settings>Akismet Anti-spam.
  4. In the dashboard, click Manually Enter an API key.
  5. Enter your Akismet API key.
  6. Click Connect with API key.
  7. In Elementor Editor, create a page with a form. For details about creating forms, see Form widget
  8. Select the form.
    Notice that when you install Akismet, a new Akismet Spam Protection section is added to the Content tab.
    [content type=”warning”]The fields in the  Akismet Spam Protection section are filled with dummy text. You’ll need to enter the shortcode information yourself for it to take effect.[/callout]
     
  9. Save or Publish the page with the form.

Add shortcodes to Akismet Spam Protection

In order for spam protection to work, you need to determine which fields to filter. For example, you can filter the email and message fields. You determine which fields to scan, by entering that field’s shortcode in the Akismet Spam Protection section.

Example: Apply spam protection to the email field:

  1. In the panel, click the Content tab.
  2. Open the Form Fields section.
  3. In the Form Fields section, click the Email field.
  4. In the Email field, click the Advanced tab.
  5. In the Advanced tab, copy the Shortcode.
  6. In the Content tab, open the Akismet Spam Protection section.
  7. Paste the shortcode into the Email field.
  8. Save or Publish the page with the form.

Test the spam filter

After setting up the spam filter, you should test to make sure it’s working.

To test the spam filter:

  1. Go to the  Akismet website
  2. There you’ll find text specifically designed to trigger the spam filter, when entered into specific fields, such as the Name field. Copy the text for one of these fields.
  3. In the Elementor Editor, go back to the page with the form you want to test. 
     
  4. Click the view icon LflYNIgeFR3e J64R8AcK9C61HGT59DTIjfZXbnAKX2yPTgTZKwZ3pmcFWFwo2aUeSul5qoqH5jV5GEC2fs8JnXB3uPBh73aXDqZcmg9Z109LWk3yzgG9m1V OG0qlTnFkHQ4X 8KIicnQvuboCNuA Block spam messages from forms 27.
  5. Paste the text you copied into the appropriate field. 
  6. Fill in all mandatory fields with dummy text.
  7. Click the button to submit the form.

    You should receive an error message.
  8. In WP Admin, check your form submissions. For details about checking form submissions, see Form submissions.

Your dummy submission should not appear. 

Have more questions? We’re more than happy to assist.

Link is copied to clipboard!
On this page

Is this article helpful?

Share this article