Once in a while I come up with issue where WordPress or WooCommerce is not sending emails to site administrators, online shop customers or visitors who will forms in a website. Most of the time the problem is that website host refuses to send emails in plain PHP for safety reasons.
It may sound complicated and too technical, but the solution is actually quite simple. You just need to install and set up a simple plugin that will fix not sending emails in WordPress issue once and for all. Instead of sending plain emails we’ll use SMTP authentication to make sure that emails we send from WordPress website are valid and don’t look as spam for recipients.
Here’s the step by step tutorial where to find SMTP information of your email, and how to send emails using SMTP in WordPress and WooCommerce:
Let’s start with the information you’ll need to setup SMTP in WordPress. Every email account has this information – it is used for setting up Outlook or Thunderbird email clients in desktop software, or it’s used for setting up email accounts on your smartphones. We’ll need to find the exact same information – SMTP host, ports, and login credentials for the email you’ll want to send emails from in WordPress.
SMTP settings for email in Cpanel are located in Email >> Emails Accounts page.
Click on Connect Devices – this page will have all sorts of SMTP details for use in WordPress or any smart devices.
In Connect Devices page look for Mail Client Manual Settings.
There will be all information you’ll need:
SMTP username
SMTP password (most of the time it’s not shown – you need to know your email login password anyway)
Outgoing server (host)
SMTP Port number
You’ll need this information for setting up SMTP in WordPress.
SMTP settings for email in DirectAdmin are located in Email Manager >> Emails Accounts page.
To view SMTP settings click View (Email Settings).
Here you’ll find all the information for SMTP setup in WordPress:
username
password probably won’t be shown, but you should know it (or you can change it in Directadmin anyway)
SMTP Host (outgoing email server)
SMTP Port
Now when you have your SMTP settings you’ll need to add it to WordPress.
If you want to be sure that your WordPress website or WooCommerce store sends emails to you or your customers is to set up SMTP connection in WordPress. Go to Plugins >> Add New, and enter SMTP to the search field at the top. The first in the results will be plugin named WP Mail SMTP by WPForms – we’ll use this plugin. Click Install Now, and Activate the plugin once it’s installed.
Once you activate the plugin it will guide you through all the setup process. Click Let’s Get Started.
If you use one of the Recommended mailers in the setup then select one, and you’ll be rady to go in few seconds. In this tutorial I’ll do it harder way – will setup SMTP manually because most website owners don’t use gmail or other dedicated email providers, they use their hosting servers to send emails. So we choose Other SMTP.
In this step you’ll need to enter the details you previously found in your Cpanel, DirectAdmin or other server panel:
SMTP host
Encryption type (most of the time it’s SSL)
SMTP Port
SMTP username and your email password
Once you fill all the SMTP details you may select additional tools offered by this plugin. We’ll only leave those top two:
You may optionally add your email to get tips about and offers from the plugin authors.
WP Mail SMTP plugin comes with some handy optional features which require a licence. But we don’t need it just for sending emails so we’ll Skip this step.
If you’ve entered all the SMTP information correctly you’ll see message Congrats, you’ve successfully set up WP Mail SMTP. In case you accidentally missed something you’ll be able to get back to the SMTP setup and rerun the wizard.
Once everything is fine click Finish Setup – now your WordPress website or WooCommerce online store should successfully send emails.
If you’ll ever need to change your SMTP password in WordPress, or make any other changes in SMTP plugin there’s no need to rerun the whole wizard. You can find all the same SMTP settings in your WordPress admin panel’s WP Mail SMTP >> Settings page.
That’s it – you just got rid of not sending emails issue in your WordPress or WooCommerce website.