If you use a computer regularly, it’s pretty likely you send and receive countless emails each day. Emails from clients, subscriptions to newsletters, messages from friends and family and not tomention spammers. Most internet users don’t know these emails are sent or arrive in their inbox, and that’s okay. From the typical email user's standpoint, it seems simple. We think of email as something that pops up when messages come through to our mail client (Thunderbird, Yahoo, Outlook, etc.).
When you send an email to your Mom, you type her email address, compose, hit send and their reply comes back to your email client. To some extent, this is true, but, there’s much more to it than that. How emails are structured and transmitted is a complex process, and with the help of relatable analogies, we can explain the entire process in an easy to absorb manner.
As simple as it seems, email relies on a different set of protocols than those used to access website content. To order, store and access emails relies on a set of protocols that’s different from what the rest of the internet depends on.
For most email users, it’s not necessary to understand how email works to use it. If you’re interested in how these messages ping into your inbox, stick with us. This short introduction has been developed to help understand the basic principles of email. It’s surprising how close the process of emailing is to the old-fashioned written format. If you’ve ever written a formal letter, you'll have no trouble getting your head around how email works.
Email was actually invented before the publicly accessible internet as we know it. Email was conceived as a means for computers to communicate with one another. From the early 1960s the computer network ARPANET, a computer communications network created by United States Department of Defense developed a system of email transfers that relied upon the now familiar "@" sign. Ray Tomlinson, the man widely acknowledged to have masterminded email as we know it chose the @ symbol deliberately.
According to Tomlinson "The primary reason was that it made sense. The @ sign didn't appear in names so there would be no ambiguity about where the separation between login name and hostname occurred. (Raytheon BBN Technologies, 11 February, 2011).
The addition of the @ symbol allowed messages to target certain users on certain machines and showed that it wasn’t sent to a local host. This separation of usernames from machine names works similar to how websites are allocated human-readable names instead of IP addresses. This resulted in email addresses taking the format username@host, and later, email@example.com once the domain name system (DNS) was developed.
Emails are routed to user accounts via several computer servers. They route the message to their final destination and store them so that users can pick them up and send them once they connect to the email infrastructure. Email can be accessed through an email client or a web interface (more about these later). When you click send, the message is transmitted from your computer to the server associated with the recipient’s address. This process typically takes places via several other servers before the message gets to its intended recipient's mailbox.
Electronic mailboxes are central to how emails work for the end user. A mailbox is where electronic mailboxes are stored, and when a user receives an email, the mail system automatically puts it in their mailbox. The mailbox makes emails user-friendly. They separate emails into folders; inbox, outbox, spam, etc. and allow users to scan mail, copy, delete, or forward it to another user. But what happens before it hits the mailbox?
Unlike your physical mailbox where one service, the post office, handles all of your mail, with email, your incoming and outgoing mail is handled differently. There’s two types of servers. The Simple Mail Transfer Protocol (SMTP), which an email delivery protocol. It’s used to send mail over the internet. SMTP contains information regarding the transmission details of an email message and is specifically used for outgoing mail. A Mail Transfer Agent (MTA) is a server program that uses SMTP to deliver emails.
There are two types of MTA, a client-based MTA which involves installing software to access emails (such as Outlook), and a web-based MTA which is accessed through a web browser (gMail for example). Anyone can use their computer to run an MTA. It’s fairly easy, and an MTA will handle incoming mail well. Running your own MTA to deliver a high-volume of bulk-emails while maintaining a good level of deliverability will get complicated. There are standards and conventions that need to be followed. Failure to adhere to them will hurt your ability to deliver mail reliably. A shorter, more straightforward route would be configuring your clients to use your ISP’s SMTP server instead of setting up and running your own.
Sending mail is a different story. SMTP relies on the TCP port 25. When an email is sent, Port 25 is typically used to route the message to a local computer that’s designated with handling e-mail by a network operator. This email server is pre-approved by the email host, and handles incoming email messages and sends on messages. The problem with Port 25 is that it gets clogged with spam emails if computers on the same network become infected with malicious software or a virus. For this reason, most anti-spam guidelines propose blocking port 25.
Unless a user hosts their own email, they can’t send mail themselves since most internet service providers block Port 25 and SMTP servers require static IP addresses to do their job. Blocking Port 25 blocking allows ISPs to eliminate any spam that’s sent out through their networks. There is a snag, blocking this port tends to punish the innocent that have a need to send through email servers other than those belonging to their ISP.
The reason for blocking anyone and everyone from sending emails themselves is to keep the internet in some working condition. Consider the massive amounts of spam that would be eating away at our collective bandwidth. Indeed, software that transfers electronic mail messages should be configured to filter it out, but if it weren’t, there would be no joy in opening that mailbox. The main thing to understand is that both an MTA and an SMTP server are needed to use email, as each is specialized for what it does.
The moment an email is sent, a message is routed from server to server via the Simple Mail Transfer Protocol until it makes its way to from the client to the email recipients email server.
So there you have it, email transmission works in virtually the same way as sending real mail. Once an email is sent, the mail server puts it in an envelope (the SMTP protocol connection). Let’s take a lot at how email is sent from a strictly technical standpoint.
Mail Transfer Agent’s (MTAs) communicate with each other over the internet using SMTP protocol (SMTP servers). The recipient’s MTA then forwards the email on to the incoming mail server (MDA, mail delivery agent) which is tasked with storing the mail until the user accepts it. To retrieve email on an MDA, a supporting protocol must be used. There are two main protocols, POP3 and IMAP. You might recognize these two acronyms since incoming mail servers are called either POP servers, or IMAP servers depending on which protocol they use.
POP stands for Post Office Protocol. This piece of software is used for retrieving email. Just like a visit to a post office you can drop in, pick up your mail and leave. POP3 gives an email user access to their emails stored in their user account on that server. You don’t need to stay online for the emails to come through. You just need to leave a copy of an email on the server to access it.
POP does have some drawbacks; namely, information transmitted through POP travels one way. This means that once an email is downloaded to a client, the client takes charge of sorting through the different status flags (e.g. sent, deleted or answered). This was fine when the internet was young, before smartphones, tablets and the like. People accessed their mail from a single location. Nowadays, it’s more likely that you access emails from many places; thunderbird at home, the mail app on your cell phone or a web interface when you are at work for example. With POP, you would have to sort through the information over each different device, that is assuming you’ve saved a copy of each email on the server, to begin with.
IMAP (Internet Message Access Protocol) is a bit smarter about how it coordinates emails. IMAP clients have two-way communication with their servers. The IMAP protocol saves a copy of every message on the server so that unlike with POP, multiple clients can access them. It’s completely synchronized. With IMAP, when you check an email on your tablet, it will be marked as read when you check your inbox on your phone. This happens because the status of the email is updated with all other clients during the server interaction.
Back to the post office analogy. IMAP is just like when your mail is categorized and stored at the post office for you and redelivers it when you are at home, at work, or pick it up there in person. You can keep a properly marked archive on your home client as well as on your mail server. IMAP has an offline mode where any changes are synced with the server the next time you’re online. You may configure IMAP mail servers to fetch mail from POP inboxes, too, which works well if you’re seeking to consolidate. Of course, given that IMAP works with the "cloud" best, servers get entry too, and storage can be problems. Thankfully, storage space and bandwidth isn’t as pricey as it once was, but this will truly be a change-off for a few humans.
Let’s now take a look at how email is received. No surprises here — we’ll revert straight back to our mail carrier analogy. How would an envelope be delivered to the recipient on the front of the envelope? The postal service will find the most logical route to the recipient.
First, the carrier will look up the route to the recipient's address. He makes his way to the recipient's address but can’t locate a mailbox so knocks on the door. Someone opens the door, and the postman asks if that person wants letter. Naturally, they will want to know where the letter was sent from, who sent it and who it’s for. Reading the address on the back of the envelope, the mailman can confirm these details. Even if the person who opened the door isn’t who the letter is addressed to, they can accept post to the addressee and sign the mail mans receipt.
The electronic version of events is handled similarly:
Retrieving email is tasked by a software programme called a Mail User Agent (MUA). There are two types of MUA and these are classed depending on how emails are accessed, via installed software (email client) or through in browser (webmail).
Let’s break down how an email is transmitted. Like most Internet data, emails travel across the internet as a stream of packets using the internet’s TCP/IP protocol. This process can be broken down into three steps:
Once an email is sent, the TCP protocol breaks it down into packets ( ), each packet bears the address of both the sender and the email recipient.
The IP protocol routes the packets to the intended destination. Routers over the world wide web examine the addresses in each packet to calculate the most efficient route to the email’s destination server. Once a pathway is planned, the packets are forwarded to the next router. Several factors go into how email packets are routed, such as the volume of traffic on any given network.
Once the packets have arrived at the recipient's email server, TCP recombines them into the email format in which it was sent (on that the recipient can read).
It might have been a while, but consider how you’d formulate a formal letter you’d take to your mail office or drop in a mailbox. You start with taking pen to paper and begin with writing your name and address on the right-hand side. On the left-hand side, you write the name and address of the intended recipient. Once you’ve written the body of the letter, you place it in an envelope. This is sealed, and the intended recipient's address is written on the front so that the sorting office knows where the letter will be sent. Just in case there is a problem finding the recipient, the sender's address is written on the back so that the post office knows who the letter should be sent back to.
As technical as email might sound, the letter analogy is the same as the way emails are structured. Emails are composed in a mail client (comparable to pen and paper), this is known as MIME data (multipurpose internet mail extensions). The mail server puts the email into an envelope which includes the recipient and sender’s addresses (this is called envelope data). Email users won’t come across the envelope since it’s part of an internal process to route an email.
An email is constructed with three parts:
The header includes the mandatory information including the sender, recipient and date. Other header lines such as subject and cc are optional. Although only mandatory headers appear to the user, the header includes other important details such as the route the email took as it was transferred from one computer to another. We’ve mentioned the job of Mail Transfer Agents (MTAs). When an email is forwarded by an MTA, it is time stamped. You’ll notice that some email, that had multiple destinations since the origination of the email, have several received headers. Most of this extra information is hidden inside the email. When viewed in their entirety they look something like this:
There’s a lot to digest here, but we hope this piece has given you some understanding of just how much goes into the seemingly-simple act of sending an email.
Starting at $11.88/yr
Web-based access to your accounts, secure storage on our private cloud, tough anti-spam protection and plenty of space!
Find out how you can host your own email server to ensure reliability and security for your business.
Get the basics of email communication right from the very start with this guide to email etiquette and protocol.
Every website on the planet is hosted somewhere. What does that mean? Find out with our guide!
Virtual Private Networks make your internet connection truly secure. Find out more about them and how they work.
Find out what that padlock symbol in your browser's address bar means and why you should care.
Instructions on how to avoid domain hijacking and other security attacks.
Discover how your domain name provider can help keep your information your own on the web.