What is SMTP?

Have you ever wondered how your email gets to its recipient?

The Simple Mail Transfer Protocol (SMTP) protocol is the bedrock of email communications, and absolutely crucial for modern-day connectivity.

SMTP is a set of rules that allow data to be sent from one email server to another and allows the exchange of online messages. It's widely used by email hosts and webmail clients everywhere, from Gmail to Outlook.com, as a means to send or receive emails outside of their own systems.

This technology was first created in the 80s by the Internet Engineering Task Force (IETF), a large open community of network designers, vendors, operators and researchers. SMTP, which is also known as RFC 821 and RFC 2821, was devised as part of the application layer of the TCP/IP protocol.

It uses a "store and forward" mechanism to shift an email from one device's mail Transfer Agent (MTA) to another, travelling through the network using a chain of store and forward actions prior to reaching its destination.

Advertisement
Advertisement - Article continues below

Either the Post Office Protocol 3 (POP3) mechanism or Internet Message Access Protocol (IMAP), is then employed to gather and transfer emails to the recipient. Both methods have their pros and cons but, generally, enterprise applications should use IMAP where needed so emails can be stored on a server as opposed to locally on individual devices. It's crucial, however, that one is specified on the server so that emails can be received properly by a device, regardless of which option you choose.

SMTP is integrated into email clients and includes four vital parts: a local user or client-end utility called the mail user agent (MUA); a server called the mail submission agent (MSA); a mail transfer agent (MTA); and a mail delivery agent (MDA).

The SMTP server

An SMTP server is just a computer running SMTP. Once messages are picked up they are sent to this server for passing onto recipients.

Six steps to (email) heaven

An email is sent from sender to recipient using six steps.

1) The email is submitted by an MUA to a mail server's MSA.

2) This email is transferred to the server's MTA via port 25 (the MTA and MSA are typically hosted on the same SMTP server).

3) The MTA confirms the MX record of the recipient domain and transfers the message to another MTA (this can happen many times until the message is received by the destination server).

4) The email is given over to the MDA, which saves the message in the correct format for retrieval by the receiving MUA.

5) The receiving MUA requests the message from the MDA via POP3 or IMAP.

Advertisement
Advertisement - Article continues below

6) Lastly, the email is delivered to the receiving MUAs inbox.

Using MIME to send attachments

SMTP is a very reliable protocol, but it is constrained to sending text only. This would make email very limited as we wouldn't be able to send any attachments. This is where MIME comes in.

MIME stands for Multipurpose Internet Mail Extensions. This is an extension to SMTP that allows users to send different kinds of files over the internet, such as audio, video, images, application programs, etc. It also allows for non-Latin characters and emails that contain multiple parts (such as an email with a plain text element and an HTML element).

SMTP Authentication

Another extension to SMTP is SMTP Authentication. This enables email clients to authenticate when connecting to an SMTP server using a username and a password. This prevents unauthorised users from sending email through an SMTP server.

Featured Resources

The IT Pro guide to Windows 10 migration

Everything you need to know for a successful transition

Download now

Managing security risk and compliance in a challenging landscape

How key technology partners grow with your organisation

Download now

Software-defined storage for dummies

Control storage costs, eliminate storage bottlenecks and solve storage management challenges

Download now

6 best practices for escaping ransomware

A complete guide to tackling ransomware attacks

Download now
Advertisement

Most Popular

Visit/cloud/microsoft-azure/354230/microsoft-not-amazon-is-going-to-win-the-cloud-wars
Microsoft Azure

Microsoft, not Amazon, is going to win the cloud wars

30 Nov 2019
Visit/business/business-strategy/354252/huawei-takes-the-us-trade-sanctions-into-its-own-hands
Business strategy

Huawei takes the US trade sanctions into its own hands

3 Dec 2019
Visit/hardware/354237/five-signs-that-its-time-to-retire-it-kit
Sponsored

Five signs that it’s time to retire IT kit

29 Nov 2019
Visit/mobile/mobile-phones/354273/pablo-escobars-brother-launches-budget-foldable-phone
Mobile Phones

Pablo Escobar's brother launches budget foldable phone

4 Dec 2019