How Long Can an Email Address Be? Every Limit, With Its Source

A standard email address can be at most 254 characters long in total. The part before the @, called the local part, can be at most 64 octets, and the domain part follows the usual domain name limits: 63 octets per label and 253 characters for the full name as normally written. The 254 figure comes from the SMTP specification, RFC 5321, which limits the "path" that carries an address to 256 octets including the angle brackets around it, leaving 254 for the address itself. You will often see 320 quoted, from adding 64, 1 and 255, but that ignores the path limit and is not the practical maximum.

The limits in one table

PartLimitSource
Local part (before @)64 octetsRFC 5321, section 4.5.3.1.1
Domain part255 octets in DNS wire format, which is 253 characters as writtenRFC 5321, section 4.5.3.1.2, and RFC 1035
Each domain label63 octetsRFC 1035
Path (address in angle brackets)256 octetsRFC 5321, section 4.5.3.1.3
Whole address, practical maximum254 charactersFollows from the path limit; confirmed in verified erratum 1690 to RFC 3696

The domain limits are the same ones covered in our table of common domain numbers and explained at length in why the label limit is 63.

Why 254 and not 320

The arithmetic that produces 320 adds the largest local part (64), the @ sign (1) and the largest domain (255). The problem is that SMTP never carries an address on its own. In the commands that send mail, the address travels inside angle brackets, for example RCPT TO:<name@example.org>, and RFC 5321 limits that bracketed path to 256 octets. Take away the two brackets and 254 remain. An informational document on checking addresses, RFC 3696, originally gave a different figure; a verified erratum corrected it to 254. That is why well-maintained validation libraries and form guidelines settle on 254.

There is a second subtlety in the domain figure. The 255-octet DNS limit counts length bytes in the wire format, which is why the longest name you can type is 253 characters. Our encoded length arithmetic walks through that calculation.

Internationalised addresses

Email addresses can contain non-ASCII characters in both parts where the mail systems support it, under the SMTPUTF8 extension described in RFC 6531. The limits are in octets, not characters, so a local part written in a script where each character takes two, three or four bytes in UTF-8 reaches 64 octets with fewer than 64 visible characters. Internationalised domain parts are handled through the same A-label conversion used elsewhere, so their encoded length is what counts; see an internationalised name, from Unicode to xn--. Support for internationalised addresses across software is part of what the Universal Acceptance effort works on, covered in qualifications related to IDNs and Universal Acceptance.

What this means for a sign-up form

Checking a borderline address by hand

Suppose a form receives a long address and you want to know whether it is acceptable. Work through it in this order:

  1. Split at the last @. Everything before it is the local part; everything after it is the domain.
  2. Count the local part in bytes, not characters, if it contains anything outside plain ASCII. It must be 64 or fewer.
  3. Convert the domain to its A-label form if it contains non-ASCII characters, then check each label is 63 octets or fewer and the whole name is 253 characters or fewer.
  4. Add the two parts and the @. The total must be 254 or fewer.

An address that passes all four checks is within the length limits. Whether it actually receives mail is a separate question that only a confirmation message can answer.

Related limits worth knowing

Email depends on several DNS records with limits of their own. SPF policies are limited to ten DNS-querying mechanisms during evaluation, a rule our illustrative SPF case shows in practice. TXT records are built from strings of at most 255 characters each, which affects long SPF and DKIM values. The guide to DNS record types and their limits and the four-week plan for email records within DNS limits cover these.

Frequently asked questions

What is the maximum length of an email address?

254 characters in practice. That follows from RFC 5321's 256-octet limit on the bracketed path that carries an address, and is confirmed by a verified erratum to RFC 3696.

How long can the part before the @ be?

Up to 64 octets, under RFC 5321. With non-ASCII characters, that may be fewer than 64 visible characters, because the limit counts bytes.

Why do some sites say 320 characters?

320 adds the maximum local part, the @ and a 255-octet domain, but ignores the SMTP path limit. Addresses that long cannot be carried by standard SMTP.

More limits, each with its source, are collected in the Learn hub.