New guide: how to warm up a dedicated IP without hurting your reputation. Read now →
Log in
MigoSMTP
SMTP and APIUpdated 17 Oct 2026

SMTP Full Form: What Does SMTP Stand For? Meaning, Commands, Reply Codes and Ports Explained

SMTP stands for Simple Mail Transfer Protocol, the standard set of rules email programs and servers use to send messages. This guide explains the full form, how an SMTP conversation works with a worked example, the main commands and reply codes, the ports 25, 587 and 465, and how SMTP differs from IMAP and POP3.

KM
Written by Karan Malhotra
API and Developer Experience Lead
Reviewed by Aarav Mehta
  • Published28 Sep 2026
  • Read time6 min
  • Length1,275 words
Share this guide

SMTP stands for Simple Mail Transfer Protocol. It is the standard set of rules that email programs and mail servers use to send messages across the internet. If you searched for the "full form of SMTP in computer", that is the answer: Simple Mail Transfer Protocol, defined today in RFC 5321. This guide explains what each word means, how an SMTP conversation works, what the commands and reply codes look like, which ports SMTP uses, and how SMTP differs from IMAP and POP3.

SSimple: a plain-text protocol of short commands and numeric replies
M TMail Transfer: it moves messages between systems
PProtocol: an agreed set of rules both sides follow

SMTP full form and meaning

The three words describe the job. Simple refers to the design: SMTP is made of short text commands and short numeric replies that a person can read. Mail Transfer says what it does: it moves mail from one system to the next. Protocol means that it is a set of rules, so software from different makers can work together. The first version appeared in 1982 as RFC 821, and the current specification is RFC 5321 from 2008.

SMTP is a push protocol. The sender connects and pushes the message towards its destination. It does not let you read or download mail from a mailbox. For that, you need IMAP or POP3, which our article on IMAP vs POP3 vs SMTP compares.

What SMTP does

When you press Send, your email program or application hands the message to an outgoing mail server over SMTP. That server looks up where the recipient's domain receives mail, connects to it over SMTP, and passes the message on. The receiving server stores it in the recipient's mailbox. Several servers may handle the message along the way, and each hand-over is an SMTP conversation. The software that performs these hand-overs is a mail transfer agent; read about the mail transfer agent to see how it fits together.

An SMTP conversation, step by step

An SMTP session is a short dialogue. The lines starting with S are from the server, and those starting with C are from the client. This is a simplified example with placeholder names.

S: 220 mail.example.net ESMTP ready
C: EHLO app.example.com
S: 250-mail.example.net
S: 250-STARTTLS
S: 250 AUTH PLAIN LOGIN
C: STARTTLS
S: 220 Ready to start TLS
   (encrypted connection begins)
C: AUTH PLAIN ...
S: 235 Authentication successful
C: MAIL FROM:<[email protected]>
S: 250 OK
C: RCPT TO:<[email protected]>
S: 250 OK
C: DATA
S: 354 Start mail input
C: Subject: Hello
C: ...message body...
C: .
S: 250 Message accepted
C: QUIT
S: 221 Bye
CommandWhat it does
EHLO (or HELO)The client introduces itself. EHLO also asks the server to list its extensions
STARTTLSAsks to switch the connection to encrypted TLS
AUTHLogs in with a user name and password or key
MAIL FROMNames the envelope sender, where bounces go
RCPT TONames one recipient; repeated for each recipient
DATABegins the message itself: headers and body, ending with a line holding a single dot
QUITEnds the session

SMTP reply codes

Every server reply begins with a three-digit code. The first digit tells you the category, which is often enough to know what to do.

Code rangeMeaningExample
2xxSuccess250 OK, 235 authenticated
3xxThe server wants more input354 start mail input
4xxTemporary failure: try again later421 service unavailable, 451 try later
5xxPermanent failure: do not retry unchanged550 mailbox unavailable, 554 rejected

Our guide to SMTP error codes explains the common ones and how to respond, and email bounce types covers what they mean for your list.

SMTP ports

PortUsed forNotes
25Server-to-server deliveryOften blocked for end users and cloud hosts to limit abuse
587Message submission from apps and mail clientsThe usual choice, with STARTTLS required
465Submission over implicit TLSEncrypted from the first byte, described in RFC 8314
2525Unofficial alternative submission portUsed when 587 is blocked, only if your provider offers it

Read SMTP settings, ports and authentication for the full settings, and email SSL and TLS for the encryption options.

SMTP, IMAP and POP3: who does what

  • SMTP sends mail from a client to a server, and between servers.
  • IMAP lets a client read and manage mail that stays on the server. See what IMAP is.
  • POP3 downloads mail from the server to one device, usually removing it from the server.

A typical mail account setup needs both an outgoing server (SMTP) and an incoming server (IMAP or POP3).

SMTP does not prove who sent a message

The base protocol lets a sender claim any From address, which is why spoofing is possible. Three DNS-based checks add proof: SPF lists which servers may send for a domain, DKIM signs messages cryptographically, and DMARC tells receivers what to do when those checks fail. Any application that sends email should set all three up.

Using SMTP in your own application

You rarely type SMTP commands by hand. Libraries and frameworks do it for you. You provide four values: a host name, a port, a security mode and credentials. If you do not want to operate your own server, use an SMTP service. See SMTP servers vs SMTP services and our SMTP relay. You can test a connection from the command line:

openssl s_client -connect smtp.example.com:587 -starttls smtp

The host name is a placeholder. A successful run shows the certificate and then the server's greeting, after which you can type EHLO by hand to see the extensions it offers.

Never send credentials without encryption. Use STARTTLS on port 587 or SSL/TLS on port 465, and make the client refuse to continue if encryption cannot be set up.

A short history of SMTP

Email existed before SMTP. Early systems moved messages between users of the same computer, and later between machines using a variety of one-off methods. SMTP was published in 1982 as RFC 821 so that different networks and systems could exchange mail with a common method. It was revised in 2001 as RFC 2821 and again in 2008 as RFC 5321, which is the version in force. The word "Simple" was meant seriously: a basic implementation fits in a few hundred lines. The protocol has stayed recognisable for more than forty years because the core idea, a short text dialogue, works.

ESMTP: the extensions that made SMTP practical

The original protocol had no way to log in, no encryption and no way to announce limits. Extensions, together called ESMTP, added them. That is why the modern greeting is EHLO instead of HELO: it asks the server to list what it supports. Common extensions include STARTTLS to upgrade to an encrypted connection, AUTH to log in, SIZE to announce the largest message accepted, PIPELINING to send several commands without waiting for each reply, and 8BITMIME to send text that is not plain ASCII. When you read a server's EHLO reply, you are reading its feature list.

The envelope and the message

SMTP separates the envelope from the message. The envelope, made of MAIL FROM and RCPT TO, tells servers where to deliver and where to send bounces. The message, sent after DATA, is what the recipient sees: From, To, Subject and the body. The two can differ, and that is normal. A mailing list, for example, uses its own address in the envelope and keeps the original author in the From header. Many deliverability checks look at how the envelope and headers line up. Read our guide to email header fields to see each one.

Need to send email from your application over SMTP? We can help you set up credentials, authentication and a first test message, so you can see how SMTP works with a real connection.

Get started

References and further reading

Frequently asked questions

What is the full form of SMTP?

SMTP stands for Simple Mail Transfer Protocol. It is the standard protocol that email programs and mail servers use to send messages, defined today in RFC 5321.

What does SMTP do?

It moves email from a sender's program to an outgoing server, and from server to server until the message reaches the recipient's mail server. It does not let you read mail from a mailbox; IMAP and POP3 do that.

Which ports does SMTP use?

Port 25 is used for server-to-server delivery, port 587 for message submission with STARTTLS, and port 465 for submission over implicit TLS. Some providers also offer 2525 as an alternative when 587 is blocked.

What is the difference between SMTP and IMAP?

SMTP sends mail. IMAP lets a client read and manage mail that stays on the server. A mail account normally needs both: an outgoing SMTP server and an incoming IMAP or POP3 server.

What do SMTP reply codes mean?

The first digit gives the category: 2xx is success, 3xx means the server wants more input, 4xx is a temporary failure that you can retry, and 5xx is a permanent failure.

Topics#smtp#simple mail transfer protocol#smtp full form#smtp commands#smtp ports#email protocols
Was this guide helpful?Your answer helps us improve our documentation.

Start sending in minutes.

Create an account, add your domain and send your first email.

Get started Talk to sales