SMTP

SMTP (Simple Mail Transfer Protocol) is the internet standard for sending email between servers and from mail clients to their outgoing server. Defined in RFC 5321, it moves each message through a sequence of commands and numeric reply codes.

Deliverability & Email InfrastructureUpdated September 30, 2026

In short

SMTP is the protocol that carries email from sender to recipient servers.

Key points

  1. RFC 5321 defines the core exchange: EHLO, MAIL FROM, RCPT TO and DATA, each answered with a three-digit reply code [1].
  2. Replies starting with 2 mean success, 4 means a temporary failure such as a Soft Bounce, and 5 means a permanent failure such as a Hard Bounce [1].
  3. Mail clients submit messages on port 587 (RFC 6409) or port 465 with implicit TLS, which RFC 8314 now recommends; servers relay to each other on port 25 [2][3].
  4. STARTTLS, defined in RFC 3207, upgrades an SMTP connection to TLS, and Gmail requires TLS from all senders [4][5].
  5. The address given in MAIL FROM becomes the Return-Path, which receives bounces and is checked by SPF (Sender Policy Framework) [1].

How an SMTP transaction works

A sending server first looks up the recipient domain's MX Record to find where to deliver. It opens a TCP connection and the receiving server greets it. The sender introduces itself with EHLO, gives the envelope sender with MAIL FROM, lists each recipient with RCPT TO, and then sends the message headers and body after DATA [1]. Every step gets a reply code, so the receiver can accept, defer or refuse at several points. The envelope addresses used here are separate from the From and To lines and the Message-ID inside the message, which are defined by RFC 5322 and shown to the reader. That split is why authentication checks such as SPF (Sender Policy Framework) and DMARC look at different addresses and why Domain Alignment matters.

Submission, relay and encryption

SMTP is used in two roles. Submission is when a mail client or application hands a message to its own provider's server, normally with authentication; RFC 6409 assigns port 587 for this [2], and RFC 8314 recommends implicit TLS on port 465 for clients [3]. Relay is server-to-server delivery on port 25, which many networks block for ordinary devices to limit spam. Encryption between servers is usually negotiated with STARTTLS from RFC 3207 [4]. Gmail's sender guidelines require a TLS connection for all mail sent to Gmail [5], and a failure to use TLS can produce 4xx errors. Most Email Service Provider (ESP) platforms offer both an SMTP relay and an HTTP API as ways to submit mail. Reading and syncing a mailbox is a separate job, handled by IMAP or a provider API.

Why SMTP matters for deliverability

Many deliverability problems appear first as SMTP responses. Throttling shows up as 421 or 450 deferrals, authentication failures as 5.7.x rejections, and bad data as 550 5.1.1 unknown-user errors. Reading those codes, rather than only a bounce count, tells you whether to fix DNS, slow down or clean the list. Receiving servers also judge the connection itself: a sending IP needs valid Reverse DNS (PTR Record), a sensible EHLO name and consistent volume. PineLead sends through the mailbox you connect, so messages go out through your own provider's SMTP infrastructure under your domain's SPF (Sender Policy Framework) and DKIM (DomainKeys Identified Mail) records, within a daily send limit, and replies arrive back in the same Email Thread.

Sources
  1. RFC 5321: Simple Mail Transfer Protocol — RFC Editor
  2. RFC 6409: Message Submission for Mail — RFC Editor
  3. RFC 8314: Cleartext Considered Obsolete: Use of TLS for Email Submission and Access — RFC Editor
  4. RFC 3207: SMTP Service Extension for Secure SMTP over Transport Layer Security — RFC Editor
  5. Email sender guidelines — Gmail Help
External sources open in a new tab.

Related terms

Mentioned in

Outreach without the busywork.

PineLead finds new B2B prospects every day, qualifies them against your criteria and writes the first email in your voice. You approve — PineLead sends.

Start free with 100 credits →