Mail Transfer AgentMTA

Definition

A Mail Transfer Agent (MTA) is the server software that routes and relays email between mail servers using SMTP. When you hit send, your message passes through one or more MTAs that look up the recipient’s MX record, open a connection, and hand the message off until it reaches the destination. Postfix, Exim, and Sendmail are the best-known examples.

  • It is the server-to-server delivery engine of email, not the app you read mail in
  • MTAs queue, retry, and relay messages, and generate bounces when delivery fails
  • The IP an MTA sends from carries the IP reputation receivers judge
  • Its HELO/EHLO name and reverse DNS are checked on every connection
At a glance
Category Mail server software
Protocol SMTP (RFC 5321)
Job Route & relay mail between servers
Examples Postfix · Exim · Sendmail
Listens on Port 25 (server to server)
Related agents MUA · MSA · MDA

What an MTA does

An MTA is the piece of software that actually moves email across the internet. When it has a message to deliver, it reads the recipient’s domain, queries DNS for that domain’s MX record to find the receiving mail server, opens an SMTP connection on port 25, and transmits the message. If the receiving server is busy or temporarily unavailable, the MTA holds the message in a queue and retries on a back-off schedule rather than discarding it.

Because one message can hop through several servers on its way to the inbox, a single MTA often acts as a relay, accepting mail from one server and passing it to the next. Each MTA that handles a message stamps it with a Received: line, which is why the email header reads like a travel log of every hop.

Where the MTA sits: MUA, MSA, MTA, MDA

The MTA is one link in a chain of four agents, and confusing them is the most common source of mistakes:

  • MUA (Mail User Agent): the client you compose and read mail in, such as Outlook, Apple Mail, or the Gmail web app.
  • MSA (Mail Submission Agent): accepts your outgoing message from the MUA, usually on the submission port 587, authenticates you, and hands it to an MTA.
  • MTA (Mail Transfer Agent): relays the message server to server over SMTP until it reaches the recipient’s mail system.
  • MDA (Mail Delivery Agent): takes final delivery and drops the message into the recipient’s mailbox, where their MUA can fetch it.

In practice a single product like Postfix can play several of these roles at once, but the distinction matters: SPF, reverse DNS, and reputation checks all happen at the MTA-to-MTA boundary, not at the client.

MTAs and sender reputation

Every outbound MTA sends from a specific IP address, and that IP is what receiving servers grade. The moment your MTA connects, the receiver checks the connecting IP against DNSBLs, confirms that its PTR record and forward DNS match (FCrDNS), and reads the name it offered in HELO/EHLO. A misconfigured MTA, missing reverse DNS, a HELO name that does not resolve, or an open relay that strangers can abuse, is one of the fastest routes to the spam folder or an outright block.

This is why a poorly tuned self-hosted MTA can struggle where an ESP succeeds. The ESP runs hardened, well-warmed MTAs with clean reverse DNS, authentication, and feedback loops already in place. If you run your own, the operational burden of keeping the MTA configured correctly, off blacklists, and properly warmed up falls entirely on you.

A reverse-DNS lookup confirming an MTA’s sending IP resolves to a real hostname
$ dig -x 203.0.113.10 +short
mail.example.com.

How an MTA moves a message

Your MUA submits the message to an MSA on port 587
The MSA hands it to the sending MTA
The MTA looks up the recipient domain’s MX record
It opens an SMTP connection on port 25 and relays the message
The receiving MTA hands off to the MDA, which delivers to the mailbox

MUA vs MSA vs MTA vs MDA

MUA MSA MTA MDA
Role Read & compose Accept submission Relay server to server Final delivery
Example Outlook, Apple Mail Submission service Postfix, Exim Dovecot LDA, procmail
Typical port 143/993 (read) 587 25 local

Common mistakes

Running an MTA as an open relay
An MTA that relays mail for anyone, not just your own users, will be abused by spammers and blacklisted within hours. Lock relaying to authenticated senders and known networks only.
Ignoring reverse DNS on the sending IP
Receivers check that your MTA’s IP has a PTR record matching its forward DNS. A missing or mismatched PTR is a classic reason self-hosted mail lands in spam.
Letting the HELO name not resolve
The hostname your MTA announces in HELO/EHLO should be a real, resolvable name that matches your reverse DNS. A bogus HELO is a common spam signal.

Frequently asked questions

What is the difference between an MTA and an SMTP server?
They overlap heavily. SMTP is the protocol used to transfer mail, and an MTA is the software that speaks it to route and relay messages. People often say “SMTP server” to mean the MTA. Strictly, the MTA is the program; SMTP is the language it uses.
Is Gmail an MTA?
Gmail’s back end includes MTAs that relay mail in and out, but the part you interact with, the web and mobile apps, is the MUA. Google is acting as a mailbox provider, running MTAs and MDAs behind the scenes.
Do I need to run my own MTA to send email?
No, and most senders should not. Using an ESP means their well-maintained MTAs, reverse DNS, authentication, and reputation work for you. Running your own MTA only makes sense when you have the expertise to keep it off blacklists and properly configured.
Reviewed by Jennifer Jackson, Email Deliverability Analyst · June 2026 ← Back to glossary