Amazon SES to Mailtrap:
A Migration Guide

This guide covers core principles of how to migrate from Amazon SES to Mailtrap seamlessly: terminology comparisons, SMTP, or API Configurations, and other tech specifications needed for the smooth switch.

Mailtrap and SES Differences

  1. The main difference between Amazon SES and Mailtrap is that you don’t need extensive coding skills and experience to set up and integrate Mailtrap.
  2. Your emails are stored under Mailtrap Email Logs for up to 30 days, depending on your pricing plan. We also store email content and hard data between 3 and 7 days.
  3. Mailtrap offers monthly recurring plans with an option to request annual billing/plan. Unlike Amazon SES, Mailtrap doesn’t feature a pay-as-you-go plan, but we have a 1000-emails free plan to test and evaluate our service. 
  4. Mailtrap offers Email Testing. This is a separate product to inspect HTML/CSS, spam scores etc. and debug emails in staging, dev, and QA environments before sending them to recipients.
  5. Mailtrap features a Bulk Stream which allows you to send emails to many recipients at once (newsletters, product updates, marketing promotions, etc.).
  6. Another key difference between Amazon SES and Mailtrap is how to access all metrics. Mailtrap features Actionable Analytics where, you can get in-depth stats for your emails.
  7. Amazon SES doesn’t allow you to add unsubscribe options to emails without coding.

Mailtrap and Amazon SES – Similarities

  1. Support for sending with SMTP or REST API.  
  2. You can use return-path records and DKIM to verify a domain. 
  3. When sending from a newly added domain, the throughput gets queued or throttled.
  4. You can add a .csv file to import suppressed email addresses. 

Terminology comparison

  • Identity and Access Management (IAM)
  • Template (CreateTemplate – API operation)
  • Account-level suppression list
  • Message Tags (closest comparison, but the logic is different)
  • Event Notifications
  • CONFIGURATIONSET (you have to store all the headers in configuration and create it in advance) or use

    SendRawEmail API method

  • Message Tags

General step-by-step migration flow

  1. After signing up for Mailtrap, go to Sending Domains menu. Add your domain and proceed to verify it.

  2. If you choose SMTP service, switch the sending settings as per the credentials Mailtrap provides. See info under the SMTP header below.

  3. Should you select API integration, check API documentation and Mailtrap libraries.

  4. Take the time to understand the main differences between Amazon SES and Mailtrap as shown above.

    Need some help?

    Contact our support and our tech experts will help you with it.

  5. If you need to send more than 200K emails a month, don’t hesitate to get in touch with Mailtrap support. We’ll schedule a call with you to make sure you transition properly.

    Mailtrap Tip

    Use ActionMailer Balancer Ruby gem to proportionally distribute the email sending load between two different sending services (e.g. 60% AWS SES and 40% Mailtrap) to mitigate the sending risks.

Getting started

It doesn’t take much to get started with Mailtrap. You only need to create an account, then proceed to set up and verify your domain from the Sending Domains menu. Check our Getting Started Guide for more information and here’s a quick walk-through:

Domain verification

  • After you sign up, then add and verify your domain, it undergoes a security check, which usually takes two business days. During that time, your throughput is limited to 50 emails per hour to prevent system abuse. Read our article on Sending Limits to learn more. 
  • It’s critical not to delete and re-add during the security check as it’ll be regarded as suspicious behaviour. 
  • You can get the limitation lifted with a support ticked where you’ll be asked to answer a few questions to prove your domain’s trustworthiness. 
  • Make sure you set unsubscribe options with Mailtrap and import your suppression lists from Amazon SES.

SMTP

Switching over from Amazon SES SMTP service is straightforward. Check the sections below to get a better understanding of the compatibility and the necessary steps. 

Sending Servers 

Amazon Servers

live.smtp.mailtrap.io
bulk.smtp.mailtrap.io
email-smtp.us-east-2.amazonaws.com (+16 more) Show all
email-smtp.us-east-1.amazonaws.com
email-smtp-fips.us-east-1.amazonaws.com
email-smtp.us-west-1.amazonaws.com
email-smtp.us-west-2.amazonaws.com
email-smtp-fips.us-west-2.amazonaws.com
email-smtp.ap-south-1.amazonaws.com
email-smtp.ap-northeast-3.amazonaws.com
email-smtp.ap-northeast-2.amazonaws.com
email-smtp.ap-southeast-1.amazonaws.com
email-smtp.ap-southeast-2.amazonaws.com
email-smtp.ap-northeast-1.amazonaws.com
email-smtp.ca-central-1.amazonaws.com
email-smtp.eu-central-1.amazonaws.com
email-smtp.eu-west-1.amazonaws.com
email-smtp.eu-west-2.amazonaws.com
email-smtp.eu-west-3.amazonaws.com
email-smtp.eu-north-1.amazonaws.com
email-smtp.sa-east-1.amazonaws.com

Ports

PortFunction
587The recommended SMTP relay with TSL. 
25High traffic, blocked by some mailbox providers due to abuse.
2525Alternative port, in case you encounter issues with other ports. 

SMTP Configuration

After successfully verifying your domain, select that domain and go to SMTP/API Settings tab. Choose Transactional or Bulk Stream based on the type of emails you’d like to send.

Copy-paste the credentials (for the stream you chose) into your app or project, and proceed to send a confirmation email to verify the setup. Check our Sending Domain Setup article for more information on how to do it.

Note: Turning TLS on is mandatory as mentioned in the credentials.

API

Mailtrap API tokens explained

Mailtrap automatically creates a token when you create a domain, and the token has a Domain Admin access permission by default. You can Edit permissions for that token to authorize it with other domains on your account.

For more information on how to manage API tokens, check our guide.

API Mapping

API typeMailtrapSES Naming
The BasicsGeneralWelcome
SendingSend emailSendEmail, SendRawEmail,
SendTemplatedEmail
Email TestingEmail Testing API

API Libraries

At the moment there are five libraries available at Mailtrap.

Programming LanguageMailtrapAmazon SES
NodeJSNodeJS SDKNot supported
RubyRuby SDKRuby SDK
PHPPHP SDKPHP SDK
PythonPython SDKPython SDK
ElixirElixir SDKNot supported

API Authentication

Mailtrap uses Bearer authentication. So, you need to pass the API token under Authorization header of your email.

User management

Starting from the Business plan on Mailtrap Email API, you can add users to your account and manage their permissions. Clicking on User Management under Settings reveals all users in a particular account where you can easily add new members and assign their permissions.

Based on the permissions users get, they’ll be able to view, access, and/or modify specific functionalities of an app. Note that a user needs Admin permissions to get authenticated and send emails via API.

Read more about managing users permissions.

ActionMailer Balancer for smooth migration

For Ruby on Rails applications, Mailtrap offers ActionMailer Balancer that makes the migration smooth. ActionMailer extension allows proportionally distributing the email sending load between two different sending services and mitigating the sending risks.

After you install the Balancer to your application and do some minor configurations, it will extend the sending method of ActionMailer.

For more detailed info on the boilerplate and use in development, read the Mailtrap ActionMailer Balancer Github page.