How to Block SPAM Contact Form Submissions

Mark Walker WordPress Leave a Comment

If you run a website on¬†WordPress AND use Contact Form 7 for your contact forms, you’ve no doubt experienced SPAM submissions. In fact, you’ve probably received this exact email:


Old Ed Frez and me are good friends. Apparently, he even found our company from a direct referral, although he never has responded to my question about who that referral is. I’d say he was sending me this email 2-3 times a month for the last year or so and I was starting to get irritated. You’ll notice at the bottom of his email that I could simply reply to him and ask him to take me off his list. Well, I tried that. Several times I’ve tried that and he keeps on emailing me. After months of wondering what to do, I decided it was time to put an end to this. I should say, Ed is not the only one emailing me on a regular basis about things like this. We¬†receive a ton of unsolicited emails that are both unwelcome and unprofessional. We certainly appreciate and encourage legitimate contact form submissions, but this (and the others like it) are SPAM because they are not at all targeted for us. You might notice in the above example the sender is contacting us to see if we want to improve our website, which happens to be one of our core services. He obviously didn’t pay attention to our site or care that his email was not going to be relevant. Sorry Ed, that kind of carelessness gets you in trouble.

To combat this issue, I decided to use the “comment blacklist” WordPress feature, which works perfectly with Contact Form 7. You’ll find this feature in the WP backend under Settings–>Discussion.

spam comments

This feature allows you to block any name, URL, email, or IP. I’ve included the top 3 that kept contacting us and never responding to my request to remove us from their lists.

Beyond the blacklist, I took it one step further to add just a hint of guilt to the equation. Using Contact Form 7, I created a custom alert for anyone on this list so they will know why their submission did not go through.


Sometimes, a little shame can go along way. Hopefully these folks realize what they are doing is wrong and will stop bombarding website admins with SPAM. Have you had to take similar measures on your website? I’d love to hear your story in the comments section.


Share on social:

Leave a Reply

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