Features

Inbound email routing

Inbound email routes enable MailerSend to receive emails on your behalf, parse incoming emails, and integrate them into your application.

MailerSend interface for creating an inbound route.

Quickly integrate inbound emails

Instantly create an inbound route using an auto-generated MailerSend email address. Set up new inbound routes straight from the dashboard or via API with the inbound routing endpoint.

Examples of inbound message activity.

Create conversations

Enable users to post replies, add comments and respond to emails. Inbound content will be parsed seamlessly to your app using JSON.

Examples of inbound routing domains.

Use branded inbound domains

Ensure brand consistency by using a custom inbound domain or subdomain, and route inbound messages to the right teams by using specific domains for sales, support and more.

The MailerSend interface for creating an inbound route with priorities.

Implement custom flows with priorities

Create multiple routes for a single sub-domain and then use prioritization to manage their processing. Design advanced custom flows that route messages to the right place every time. 

MailerSend options for creating inbound routing filters.

Define inbound email rules

Set up your domain to receive all emails and configure workflow rules to filter them by email address, domain or headers. You can then route emails to different endpoints based on those rules.

An example of the code for an inbound message.

Forward or parse incoming emails

MailerSend manages inbound messages by processing incoming emails and their attachments, and then posting them to your app via webhooks, or by forwarding them to a specified email address.

Manage inbound routes via API

Use the MailerSend API in your favorite programming language to create, update, delete and retrieve inbound routes.
Read our API docs
curl -X POST \
https://api.mailersend.com/v1/email \
    -H 'Content-Type: application/json' \
    -H 'X-Requested-With: XMLHttpRequest' \
    -H 'Authorization: Bearer {place your token here without brackets}' \
    -d '{
        "from": {
            "email": "your@email.com"
        },
            "to": [
        {
            "email": "your@client.com"
        }
        ],
        "subject": "Hello from MailerSend!",
        "text": "Greetings from the team, you got this message through MailerSend.",
        "html": "Greetings from the team, you got this message through MailerSend."
    }'
use MailerSend\MailerSend;
use MailerSend\Helpers\Builder\Recipient;
use MailerSend\Helpers\Builder\EmailParams;

$mailersend = new MailerSend(['api_key' => 'key']);

$recipients = [
new Recipient('your@client.com', 'Your Client'),
];

$emailParams = (new EmailParams())
->setFrom('your@email.com')
->setFromName('Your Name')
->setRecipients($recipients)
->setSubject('Subject')
->setHtml('Greetings from the team, you got this message through MailerSend.')
->setText('Greetings from the team, you got this message through MailerSend.');

$mailersend->email->send($emailParams);
php artisan make:mail ExampleEmail

Mail::to('you@client.com')->send(new ExampleEmail());
const Recipient = require("mailersend").Recipient;
const EmailParams = require("mailersend").EmailParams;
const MailerSend = require("mailersend");

const mailersend = new MailerSend({
    api_key: "key",
});

const recipients = [new Recipient("your@client.com", "Your Client")];

const emailParams = new EmailParams()
    .setFrom("your@email.com")
    .setFromName("Your Name")
    .setRecipients(recipients)
    .setSubject("Subject")
    .setHtml("Greetings from the team, you got this message through MailerSend.")
    .setText("Greetings from the team, you got this message through MailerSend.");

mailersend.send(emailParams);
package main

import (
    "context"
    "fmt"
    "time"

    "github.com/mailersend/mailersend-go"
)

var APIKey string = "Api Key Here"

func main() {
    ms := mailersend.NewMailersend(APIKey)

    ctx := context.Background()
    ctx, cancel := context.WithTimeout(ctx, 5*time.Second)
    defer cancel()

    subject := "Subject"
    text := "Greetings from the team, you got this message through MailerSend."
    html := "Greetings from the team, you got this message through MailerSend."

    from := mailersend.From{
        Name:  "Your Name",
        Email: "your@email.com",
    }

    recipients := []mailersend.Recipient{
        {
            Name:  "Your Client",
            Email: "your@client.com",
        },
    }

    variables := []mailersend.Variables{
        {
            Email: "your@client.com",
            Substitutions: []mailersend.Substitution{
                {
                    Var:   "foo",
                    Value: "bar",
                },
            },
        },
    }

    tags := []string{"foo", "bar"}

    message := ms.NewMessage()

    message.SetFrom(from)
    message.SetRecipients(recipients)
    message.SetSubject(subject)
    message.SetHTML(html)
    message.SetText(text)
    message.SetSubstitutions(variables)

    message.SetTags(tags)

    res, _ := ms.Send(ctx, message)

    fmt.Printf(res.Header.Get("X-Message-Id"))

}
from mailersend import emails

mailer = emails.NewEmail()

mail_body = {}

mail_from = {
    "name": "Your Name",
    "email": "your@domain.com",
}

recipients = [
    {
        "name": "Your Client",
        "email": "your@client.com",
    }
]

mailer.set_mail_from(mail_from, mail_body)
mailer.set_mail_to(recipients, mail_body)
mailer.set_subject("Hello!", mail_body)
mailer.set_html_content("Greetings from the team, you got this message through MailerSend.", mail_body)
mailer.set_plaintext_content("Greetings from the team, you got this message through MailerSend.", mail_body)

mailer.send(mail_body)
require "mailersend-ruby"

# Intialize the email class
ms_email = Mailersend::Email.new

# Add parameters
ms_email.add_recipients("email" => "your@client.com", "name" => "Your Client")
ms_email.add_recipients("email" => "your@client.com", "name" => "Your Client")
ms_email.add_from("email" => "your@domain.com", "name" => "Your Name")
ms_email.add_subject("Hello!")
ms_email.add_text("Greetings from the team, you got this message through MailerSend.")
ms_email.add_html("Greetings from the team, you got this message through MailerSend.")

# Send the email
ms_email.send
The MailerSend analytics dashboard.

Review activity and analytics

Keep tabs on the number of emails received by your inbound domain—including subject lines and JSON payloads—and track replies sent to an endpoint or email address.

A view of webhook in the MailerSend app.

Monitor inbound messages with webhooks

Use the inbound_forward.failed webhook event to receive real-time notifications when an inbound email fails to be forwarded, so you can take action right away. Never miss a message and keep users happy. 

Award-winning technical support

Our award-winning, human customer support team is always available to help with setting up your account, using advanced features and troubleshooting.

93% satisfaction rate
100% response rate
24/7 support hours

Created for all businesses

MailerSend integrates quickly into your tech stack, scales with your sendings, and ensures that your emails get delivered.
What's really worth mentioning is the outstanding customer support. Replies within minutes. MailerSend is extremely easy to use and super fast to set up. I was able to send the first email via the API in minutes.
Tobias R. Self-employed, Information Technology and Services
MailerSend has been extremely reliable and fast, with a more generous free tier and no hassle for my legitimate use of the software as a transactional system. Sendgrid required a lot of forms and pleading to use for my own clients.
Frank B. CEO, Software Company
Easily design HTML emails!

The templates option is great for both clients and developers alike. You can easily design HTML emails and fill in the information easily through the API.
James R. Web Developer, Computer Software

Frequently Asked Questions

Why would I need inbound email routing?

Inbound routing enables your users and customers to interact with your app, creating 2-way conversations with customers. They help you streamline communication, making sure you keep track of important messages and they get routed to the correct location.

What is the difference between "Routing to a specific mailbox" and "Routing to a specific domain"?

You can create an inbound route that forwards any incoming messages to a specific mailbox by entering the exact email address. This means the incoming message will be filtered by the recipient and will only be received if the recipient matches the filter, like sales@domain.com. By filtering to a specific domain, like *@domain.com, you allow all emails sent to a domain to be routed and sent out to your email or endpoint.

What is the difference between "forwarding" and "routing" an email?

Email forwarding involves collecting data from one device and sending it to another. Email routing involves moving the data between devices, for example, moving an incoming email through MailerSend to be parsed and sent to your app. 

Do emails processed with the inbound route count toward my quota?

Any inbound emails forwarded or posted to your endpoint URL are counted against your monthly usage. One forward is equivalent to one sent email. So, if you have a combination of 4 endpoint URLs and forwarding addresses, it will count as 4 emails against your monthly usage.

Implement inbound email routes now

Take control of email delivery and enhance your customer experience with inbound routing. Try it now—sign up for a Premium plan starting at $30/month for 50,000 emails + more advanced features.

More features to explore

MailerSend is packed full of features that help you save time and grow your business.