Configuring WordPress to Send Email with SMTP

Updated on July 4, 2018

SMTP stands for Simple Mail Transfer Protocol, and sending through an SMTP server means that you have set up a real email address on your system and you are allowing the web based script (wp_mail) to connect to the server with the appropriate account credentials.

By default, WordPress uses the PHP Mail function to send emails. However, it is not the best method and may decrease email deliverability. Emails may often arrive in the spam/junk folder. As an alternative, you can use SMTP to send emails.

In this article we’ll explain how to choose and configure an SMTP service, as well as how to integrate it into WordPress.


Choosing an SMTP Service

There is a wide range of free SMTP servers that can be set up on a mail client to deliver your emails.

A a public outgoing server is a good choice for daily communication. You can select among different free SMTP services. The most popular are:

When it comes to email marketing though – when you need to send a bulk message like a newsletter – things get much trickier.

In fact, a common SMTP server like Gmail is not designed to support such kind of mass emailing, because it relies on shared IPs and sets strict limits to the volume of messages and recipients that you can handle per day.

So in this case it’s better to use a premium SMTP service that can guarantee full deliverability of your emails.

Some examples of the paid services include:


Recommended Hosting Solutions

The following hosting services offer maximum compatibility with Jupiter and provide exclusive discounts to Artbees Themes users:

InMotion > Up to 50% Discount
WPEngine > 20% Discount
DigitalOcean > $10 Discount
MediaTemple > 2 Months free on Annual Plan


Registering for an SMTP Service

Let’s set one of the free SMTP services. In our case, Gmail.

Google’s GMail SMTP server is a free service for anyone who has a GMail account. If you don’t have a GMail account, you can create one at the GMail account creation page.

When you’ve created the account, you’ll need to configure your mail client to use GMail for the outgoing mail server. As an example we’ll describe the configuration of the Thunderbird mail client.

1Download Mozilla Thunderbird and install it on your computer.
2Open it and go to Tools > Account Settings.
3Under the Account Actions dropdown at the bottom left side, select Add Mail Account.
4Enter your name in the given box. Write your email address and password in the required fields and click on the Continue button.
5Thunderbird will try to configure your settings automatically.  We suggest to to filling in the settings manually, so click on the Stop button on the right.
6Then click the on Manual Setup button to fill in the settings manually.
7Click on Outgoing Server (SMTP) on the left pane. Select smtp.gmail.com (Default) from the list and click on the Edit button.
8A small SMTP Server window will appear. Now enter the settings given below:

Outgoing Mail (SMTP) Server: smtp.gmail.com

Use Authentication: Yes

Use Secure Connection: Yes (this can be TLS or SSL depending on your mail client)

Username: your GMail account, e.g. user@gmail.com

Password: your GMail password

Port: 465 or 587

If you use Google Apps with your domain name, you should write that email account with the Username: field, e.g. user@yourdomain.com

9On the left, click on the first option, i.e. the name of your email (user@yourdomain.com). On the right side, fill in your email address in the Account Name field. In the Outgoing Server (SMTP) dropdown, select the server setting you configured in step 8. Click OK.

Choosing an SMTP Plugin

There are many WordPress plugins that help you to integrate an SMTP service into your WordPress website. Some of them are listed below, and for this article, we’ll explain about the WP Mail SMTP plugin.

Installing the WP Mail SMTP Plugin

To install the plugin please follow these steps:

1From the WordPress left menu, go to Plugins > Add New.

smtp service

2In the Add Plugins page, search for WP Mail SMTP and click on Install Now.

smtp service

 

3WordPress will handle the download and installation of the plugin for you. Once complete, click on Activate Plugin to activate it.

smtp service

Configure the Plugin

To add the SMTP details into the plugin:

1From the left WordPress menu, go to Settings > Email.

smtp service

2Fill in the form with the necessary information.

Setting Description

From EmailEmail address you want to send emails from – email@yourdomain.com, for example.
From NameName that your emails will be received from.
MailerChoose whether you want to use the default mail function or the SMTP.
Return PathCheck if you want to match the return path for your emails to the sending email.
SMTP HostHostname for your SMTP server.
SMTP PortPort your server works on.
EncryptionIf you have SSL/TLS encryption available for that hostname, select it here.
AuthenticationCheck if your SMTP server requires authentication.
UsernameUsername for your SMTP server.
PasswordPassword for your SMTP server.

3Click on the Save Changes button.

Testing the Plugin

If you want to test your settings, you can go to the Send a Test Email section and enter an email address that you want to send to, then click the Send Test button.

Now WordPress is configured to work with your SMTP server.

Did this answer your question?