The contact form is an essential part of a website. WordPress provides many contact form plugins for free to create beautiful and professional forms for general contact, business proposal, subscription, registration for courses, and more. This is actually a big part to collect real leads to increase a business online and offline.
In some case, WordPress automatically install and activated some form-plugin of when WordPress is installed. Mostly “WP Forms” is a common form that’s installed and activated automatically. This is a very useful form to make custom forms easily from scratch.
But in this blog post, we are going to describe and solve the “Contact form 7” form builder plugin. This is the most uses WordPress plugin and this plugin was created in the WordPress directory a long time ago.
This post is related to fixing Email sending issues that are very common now.
If your hosting/server not causing any issues then go to your “Contact form 7” “Mail” tab, in the mail setting you can see 1st field for “To” which means where the form submission will go (admin receiving email). Put your email (Gmail is the best option) if you are using any other custom email/webmail then it can be set up SMTP which we will discuss later in this post.
The 2nd field is very important, that’s called “From”. Put the email address from where the email will go to the admin. Must note: in this field, you have to put the same domain email where the contact form is installed. If your domain is “example.com” then put the email as “wordpress@example.com“, “info@example.com“, “no-reply@example.com” or like this.
This is the most common part people do wrong, mostly this case happens if the website is cloned or migrated from another domain or subdomain.
If your contact form still not working, then follow the next step. This is about SMTP (Simple Mail Transfer Protocol).
Go to Plugins > Add New and search for “smtp”. There are a lot of SMTP plugins will show but the most uses SMTP plugin is “WP Mail SMTP by WPForms – The Most Popular SMTP and Email Log Plugin” check the author of this plugin is “WPForms”. After installing and activating the plugin, you can skip the wizard. Now go to the SMTP plugin setting called “WP Mail SMTP” on the WordPress sidebar and set the “Mailer” to Default (None). Now save the setting, and your form is ready to send the emails.
In some of the cases, after the setup of this SMTP plugin, Contact Form 7 (CF7) can get spamming issues and show the wiring message when you submit the form “There was an error trying to send your message. Please try again later”
Don’t worry, you just need to add Google reCAPTCHA to fix the spamming problem.
Go to “Add New” plugin and search for “recaptcha”, install and activate the plugin called “ReCaptcha v2 for Contact Form 7” the author of this plugin is “IQComputing“. Now you will see a new option under “Contact > reCaptcha Version” on the WordPress sidebar menu, just go there and set “Select reCaptcha Usage:” to “reCaptcha Version 2” & save the setting.
Next, go to “Contact > Integration” then find the “reCAPTCHA” tab and setup the integration. It will ask you to Google reCAPTCHA site key and secret key.
In this case you have to go to Google reCAPTCHA admin and create the keys by following the instruction below.
Now submit, and you will see full-page popup windows with your 2 keys. Just copy and paste it to the WordPress setting as we describe above.
Now you can add the reCAPTCHA in your Contact form (CF7). Go to form > Edit, in the form fields tab you can see a new option to add called “reCaptcha”. Just insert it before the submit button on this form and save.
You are all set, test the form now it will send the email as we expect.
If you’re still facing the Email sending issue, then you have to use an SMTP “Mailer”. Go to WP Mail SMTP > Setting and select any of these as you want and follow the setup instruction by the plugin. Also, you can your own mail server that you may get from the hosting provider you are using.
Put these all in the WordPress setting and save. You are fully ready to use your Contact Form 7 now.
Note: Use the reCAPTCHA no matter what Mailer you are using.
Contact us if you have still any issues with this.