---
title: "What is StartTLS?"
description: "StartTLS is an email protocol command that upgrades an existing plain-text SMTP connection to an encrypted TLS connection. It starts unencrypted, then the client sends the STARTTLS command, and the server and client perform a TLS handshake before any credentials or email are transmitted. Port 587 is the standard port for StartTLS, while port 465 uses implicit TLS, which encrypts from the first byte. StartTLS is vulnerable to man-in-the-middle attacks during the initial unencrypted handshake, and enforced TLS with MTA-STS can close that gap. TLS 1.2 or higher should be used, as TLS 1.0 and 1.1 are deprecated and SSL is retired."
---

# What is StartTLS?

[Twilio](https://yomu.fyi/company/twilio) · Jesse Sumrak · Nov 4, 2026

**Type:** Explainer

## Summary

StartTLS is an email protocol command that upgrades an existing plain-text SMTP connection to an encrypted TLS connection. It starts unencrypted, then the client sends the STARTTLS command, and the server and client perform a TLS handshake before any credentials or email are transmitted. Port 587 is the standard port for StartTLS, while port 465 uses implicit TLS, which encrypts from the first byte. StartTLS is vulnerable to man-in-the-middle attacks during the initial unencrypted handshake, and enforced TLS with MTA-STS can close that gap. TLS 1.2 or higher should be used, as TLS 1.0 and 1.1 are deprecated and SSL is retired.

## Context

SMTP is not encrypted by default, so email sent without StartTLS can be intercepted and read. StartTLS encrypts each hop between mail servers but is not end-to-end encryption; mail servers along the path can still read the message.

## Approach / What changed

StartTLS is an SMTP command that upgrades a plain-text connection to TLS encryption. The client sends EHLO, the server advertises STARTTLS, the client issues the STARTTLS command, a TLS handshake occurs, and then the client sends a new EHLO over the encrypted connection before authenticating and sending mail.

## Takeaways

- StartTLS is a command that upgrades a plain-text SMTP connection to TLS; it is not the encryption protocol itself.
- Port 587 is the standard for StartTLS; port 465 uses implicit TLS, which encrypts from the start and does not use StartTLS.
- Opportunistic TLS falls back to plain text if the receiving server does not support TLS; enforced TLS blocks delivery if encryption is unavailable.

## FAQ

### What port does StartTLS use?

StartTLS typically uses port 587, the standard for email submission with encryption. Ports 25 and 2525 also support StartTLS, but port 587 is recommended for client applications. Port 465 uses implicit TLS instead of StartTLS.

### Is StartTLS secure?

StartTLS provides strong security when properly configured, but it is vulnerable to man-in-the-middle attacks during the initial unencrypted handshake. For maximum security, use StartTLS with certificate verification enabled.

### Why am I getting 'StartTLS is required' errors?

This error means the mail server requires encryption, but your email client is not requesting it. Check that StartTLS is enabled in your SMTP configuration and that you are using the correct port, usually 587.

**Tags:** [Email](https://yomu.fyi/topic/email), [Encryption](https://yomu.fyi/topic/encryption), [SMTP](https://yomu.fyi/topic/smtp), [TLS](https://yomu.fyi/topic/tls)

- Source: [Twilio](https://www.twilio.com/en-us/blog/insights/what-is-starttls)
- Source URL: https://www.twilio.com/en-us/blog/insights/what-is-starttls
- Ingested by Yomu: 2026-11-10T06:01:10.830Z

[Read original post](https://www.twilio.com/en-us/blog/insights/what-is-starttls)
