Blog / What is the SMTP protocol?

What is the SMTP protocol?

by SW Team

SMTP (Simple Mail Transfer Protocol) is a communication protocol that allows the transfer of e-mails. Within the OSI model, is the application layer. It was the American computer scientist Jon Postel, who contributed to the protocol, in addition to planning DNSand become an IANA administrator.

Your Quality Hosting from $3.74/month

Our Hosting gives you the freedom to tailor your website to your brand and goals.

How the SMTP protocol works

In short, it is the protocol responsible for sending e-mails. When a user with his mail manager, be it Webmail, Mac Mail, Outlook or Thunderbird, composes a message and clicks on “Send message”, the message travels through the sender's SMTP server, which sends it to the recipient's server. The SMTP protocol only handles the sending of e-mails, not the receiving of e-mails, as would be the case with the IMAP or POP protocols. Below is a basic diagram of how the SMTP protocol works.

               +----------+                +----------+
   +------+    |          |                |          |
   | User |<-->|          |      SMTP      |          |
   +------+    |  Sender- |Commands/Replies| Receiver-|
   +------+    |   SMTP   |<-------------->|    SMTP  |    +------+
   | File |<-->|          |    and Mail    |          |<-->| File |
   |System|    |          |                |          |    |System|
   +------+    +----------+                +----------+    +------+


                Sender-SMTP                Receiver-SMTP

The SMTP configuration is also used at SW Hosting to integrate email delivery in cloud environments, optimizing the experience and simplifying communication management.

Main features of the SMTP protocol

Due to the authentication and encryption protocols enabled by SMTP, communications can be secure. In addition, it includes several error control methods to ensure that outgoing e-mails are delivered correctly. In the event of an error, a retry is made, or notification is given as to what has happened. Due to its standardization, it supports a wide variety of mail clients and servers, in addition to its versatility of content, from HTML messages to emails with plain text and attachments.

SMTP Security

It has no security or encryption mechanism in its base configuration. The SMTP protocol can be protected with the help of Transport Layer Security (TLS) or Secure Sockets Layer (SSL) protocols. These security layers become SMTPS, or Simple Mail Transfer Protocol Secure, and encrypt messages in order to prevent spammers or other attackers from being able to view the content of sent emails. It is crucial that you can enable SMTPS for your email.

What ports does SMTP use?

The standard port for the SMTP protocol is 25. For SMTPS traffic, ports 465 and 587 are used. Port 465 is used for implicit TLS, and is used to facilitate communications for mail services. Port 587 is used to encrypt messages using STARTTLS, which allows the email client to establish a secure connection by making a request to the mail server to update the connection using TLS.

Roles in SMTP

The main roles in SMTP are MTA (Mail Transfer Agent), MDA (Mail Delivery Agent), and MUA (Mail User Agent).

  • MTA: It is in charge of sending messages between mail servers; it receives the message from the user and sends it to the destination server.
  • MDA: It is in charge of entering a message sent by e-mail to a local mailbox.
  • MUA: It is a software used to consult the mailbox and perform actions such as reading and sending e-mails.

Limitations of the SMTP protocol

Despite covering a large number of options, it was designed without taking into account the threats of modern cybercriminals, which is prone to spam and also phishing if additional measures such as SPF, DMARC and DKIM are not used.

Use of SMTP in current services

In addition to corporate mail services, when using Gmail, Outlook or Yahoo SMTP is also used for message delivery. There are mail delivery plugins for CMS like Wordpress such as WP Mail SMTP or Easy WP SMTP or in the same configuration of Prestashop.

Conclusion

The SMTP protocol is essential for sending emails from one email server to another, where it stands out for its efficiency and adaptability. In its use, it is important to take into account the correct configuration, and to implement authentication mechanisms such as SPF, DKIM and DMARC record.

Manage it all Easily with the SWPanel App

Want to simplify the management of your business and web services? Download the new SWPanel app now.

i
Email send icon