Categories: AWS SES

Setup WordPress To Use AWS SES

Amazon SES is a very robust service for sending and receiving email within the AWS ecosystem (most people use it for sending outbound). If you're a new AWS customer, you can use it for free for one year under their free tier. Configuring your site to use AWS SES to send email to the outside world can sometimes be difficult though and that is why this post exists. Any competent system administrator will already know that you should not simply setup a web server and expect it to be able to send email to the outside world without issues. That's what email servers are for, obviously.  This was a huge problem at a job despite them having an abundance of technical knowledge. We had sites in Prod actually using localhost smtpd to send email to the company's clients, then had people wondering why there was a problem with users not receiving email, or being flagged as spam. Settings up WordPress to use SES is actually a lot easier than you think and you don't even need to touch your DNS SPF record. As a matter of fact you don't even need to think about reverse DNS (rDNS) or DKIM. This is because you will be allowing the domain to send on behalf of your domain and has SPF and DKIM setup correctly. So you will be delegating the burden of managing the more technical aspect of email servers to Amazon SES and using their massive infrastructure for practically nothing. Most things that are too good to be true usually are, but not this time.

After signing up for an account at, you will need to open a support case to move your account out of the SES sandbox. Once you've done that, navigate to SES and verify your domain which will require you to create a DNS TXT record called "_amazonses" without the quotes with a certain value you are provided by AWS SES. Once you've done that you should see a status of verified.

After your domain is verified, go to SMTP Settings on the left. Note the Server Name, you will need this later. For the US-East region this will be  Click on the Create my SMTP Credentials button. You could change the name to make it reflect its purpose. An example is ses-smtp-user.contosocom. Click Create and download the credentials on the next page by clicking the button in the bottom right of the screen. You will need both values of SMTP Username and SMTP Password

Go to your WordPress Admin dashboard and install the plug-in called WP Mail SMTP and go to the settings for email.Fill in your From Email and From Name fields. Make sure Send all email through SMTP is checked instead of the PHP mail() function. Set the SMTP Host field to whatever server name was provided to you on the SES Settings page of SES.

SMTP Port: 587 (if that doesn't work try 25 or 465

Use TLS encryption. This is not the same as STARTTLS. For most servers SSL is the recommended option.

Check the box Yes: Use SMTP authentication.

Username: Enter the username of the user you created under SMTP Settings in SES. It's the weird-looking one with a long alphanumeric string of letters and numbers and not the clean one like ses-smtp-user.

Password: This is the long string of random characters.

Click on Save Changes and then send yourself a test email with the button below save. This will provide a verbose log to help you troubleshoot if any errors occur.

A Couple of things to think about are:

  1. are any ports blocked outbound from your host?
  2. is a firewall enabled?
  3. could your ISP be blocking port 25 outbound?
  4. are you underqualified to be messing around with these types of things?
  5. email headers are read bottom to top, not top to bottom


When you receive the test email you should notice that it is being sent via This is hardly noticeable to end users but if you wanted both the FROM and MAIL FROM fields to be set to your domain, additional configuration will be required.

 Received: by with SMTP id g73csp545051vke;
 Sat, 3 Sep 2016 18:04:03 -0700 (PDT)
 X-Received: by with SMTP id z32mr32385280qtc.69.1472951043619;
 Sat, 03 Sep 2016 18:04:03 -0700 (PDT)
 Return-Path: <>
 Received: from ( [])
 by with ESMTPS id 87si10830184qks.19.2016.
 for <>
 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128);
 Sat, 03 Sep 2016 18:04:03 -0700 (PDT)
 Received-SPF: pass ( domain of designates as permitted sender) client-ip=;
 spf=pass ( domain of designates as permitted sender)
 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple;
 s=6gbrjpgwjskckoa6a5zn6fwqkn67xbtw;; t=1472951042;
 Date: Sun, 4 Sep 2016 01:04:02 +0000
 From: Travis Runyard <>
 Subject: WP Mail SMTP: Test mail to
 Message-ID: <>
 X-Mailer: PHPMailer 5.2.14 (
 MIME-Version: 1.0
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
 X-SES-Outgoing: 2016.09.04-
This is a test email generated by the WP Mail SMTP WordPress plugin.
Disqus Comments Loading...

Recent Posts

VMWare vSphere 6.7 ESXTOP Output Garbled

If your VMWare vSphere 6.x environment command output of esxtop looks like a bunch of garbled gibberish (it's actually CSV… Read More

February 28, 2019 7:39 pm 19:39

How To Run RoboCopy Backup in Parallel

From time to time Windows Admins will surprise you with band-aid and bubble gum scripts, that's entirely expected I think.… Read More

February 28, 2019 12:20 pm 12:20

Windows 10 GodMode - The Ultimate Administrator Shortcut

Have you ever wondered what life might be like if the Windows 10 OS somehow had a single folder that… Read More

February 28, 2019 7:58 am 07:58

Samsung Galaxy S9 G960/G965 Stock ROM Firmware Download

There could be any number of reasons for needing to flash manufacturer stock OEM firmware on a Samsung Galaxy S9… Read More

January 24, 2019 7:42 am 07:42

Output IP Address with ipconfig Findstr Ethernet Adapter

How many times have you entered  ipconfig /all at the command line to return a single IP address, then have to strain… Read More

January 20, 2019 12:39 am 00:39

AWS SES Assistance in Enterprise Market - A Must Read

Designing e-mail solutions on a large scale can be a complex and costly challenge for a business: you need to… Read More

December 25, 2018 4:01 pm 16:01