The format of an email address is
local-part@domain, where the local-part may be up to 64
octets long and the
domain may have a maximum of 255 octets. The formal definitions are in RFC 5322 (sections 3.2.3 and 3.4.1) and RFC 5321—with a more readable form given in the informational RFC 3696 (written by J. Klensin, the author of RFC 5321) and the associated errata. An email address also may have an associated "display-name" (Display Name) for the recipient, which precedes the address specification, surrounded by angled brackets in that case, for example:
Jane Smith . Email spammers and phishers will often use "Display Name spoofing" to trick their victims, by using a false Display Name, or by using a different email address as the Display Name. Earlier forms of
email addresses for other networks than the Internet included other notations, such as that required by
X.400, and the
UUCP bang path notation, in which the address was given in the form of a sequence of computers through which the message should be relayed. This was widely used for several years, but was superseded by the Internet standards promulgated by the
Internet Engineering Task Force (IETF).
Local-part The local-part of the email address may be unquoted or may be enclosed in quotation marks. If unquoted, it may use any of these
ASCII characters: • uppercase and lowercase
Latin letters A to Z and a to z • digits 0 to 9 • printable characters !#$%&'*+-/=?^_`{|}~ • dot ., provided that it is not the first or last character and provided also that it does not appear consecutively (e.g., Jane..Doe@example.com is not allowed). If quoted, it may contain Space, Horizontal Tab (HT), any ASCII graphic except Backslash and Quote and a quoted-pair consisting of a Backslash followed by HT, Space or any ASCII graphic; it may also be split between lines anywhere that HT or Space appears. In contrast to unquoted local-parts, the addresses ".Jane.Doe"@example.com, "Jane.Doe."@example.com and "Jane..Doe"@example.com are allowed. The maximum total length of the local-part of an email address is 64 octets. • Space and special characters "(),:;<>@[\] are allowed with restrictions (they are only allowed inside a quoted string, as described in the paragraph below, and in that quoted string, any backslash or double-quote must be preceded once by a backslash); • Comments are allowed with parentheses, either at the start or end of the local-part; e.g., jane.smith(comment)@example.com and (comment)jane.smith@example.com are both equivalent to jane.smith@example.com. In addition to the above ASCII characters, international characters above U+007F, encoded as
UTF-8, are permitted by RFC 6531 when the
EHLO specifies
SMTPUTF8, though even mail systems that support SMTPUTF8 and 8BITMIME may restrict what characters to use when assigning local-parts. A local-part is either a Dot-string or a Quoted-string; it cannot be a combination. Quoted strings and characters, however, are not commonly used. RFC 5321 also warns that "a host that expects to receive mail SHOULD avoid defining mailboxes where the Local-part requires (or uses) the Quoted-string form". The local-part postmaster is treated specially—it is case-insensitive, and should be forwarded to the domain email administrator. Technically all other local-parts are case-sensitive, therefore janes@example.com and JaneS@example.com specify different mailboxes; however, many organizations treat uppercase and lowercase letters as equivalent. Indeed, RFC 5321 warns that "a host that expects to receive mail SHOULD avoid defining mailboxes where ... the Local-part is case-sensitive". Despite the wide range of special characters that are technically valid, organisations, mail services, mail servers, and mail clients in practice often do not accept all of them. For example,
Windows Live Hotmail only allows creation of email addresses using alphanumerics, dot (.), underscore (_) and hyphen (-). Common advice is to avoid using some special characters to avoid the risk of rejected emails. According to RFC 5321 2.3.11
Mailbox and Address, "the local-part MUST be interpreted and assigned semantics only by the host specified in the domain of the address". This means that no assumptions can be made about the meaning of the local-part of another mail server. It is entirely up to the configuration of the mail server. Interpretation of the local-part is dependent on the conventions and policies implemented in the mail server. For example,
case sensitivity may distinguish mailboxes differing only in capitalization of characters of the local-part, although this is not very common. For example,
Gmail ignores all dots in the local-part of user email address for the purposes of determining account identity.
Sub-addressing Some mail services support a tag included in the local-part, such that the address is an alias to a prefix of the local-part. Typically the characters following a plus and less often the characters following a minus, so fred+bar@domain and fred+foo@domain might end up in the same inbox as fred+@domain or even as fred@domain. For example, the address
joeuser+tag@example.com denotes the same delivery address as
joeuser@example.com. refers to this convention as
subaddressing, but it is also known as
plus addressing,
tagged addressing or
mail extensions. This can be useful for tagging emails for sorting, and for spam control. Addresses of this form, using various separators between the base name and the tag, are supported by several email services, including
Andrew Project (plus), Runbox (plus), and
MTAs like
MMDF (equals),
Qmail and
Courier Mail Server (hyphen).
Postfix and
Exim allow configuring an arbitrary separator from the legal character set. The text of the tag may be used to apply filtering,
Domain The
domain name part of an email address has to conform to strict guidelines: it must match the requirements for a
hostname, a list of dot-separated
DNS labels, each label being limited to a length of 63 characters and consisting of:) • example@s.example (see the
List of Internet top-level domains) • " "@example.org (space between the quotes) • "jane..doe"@example.org (quoted double dot) • mailhost!username@example.org (bangified host route used for UUCP mailers) • "very.(),:;<>[]\".VERY.\"very@\\ \"very\".unusual"@strange.example.com (include non-letters character AND multiple
at sign, the first one being double quoted) • user%example.com@example.org (% escaped mail route to user@example.com via example.org) • user-@example.org (local-part ending with non-alphanumeric character from the list of allowed printable characters) • postmaster@[123.123.123.123] (IP addresses are allowed instead of domains when in square brackets, but strongly discouraged) • postmaster@[IPv6:2001:0db8:85a3:0000:0000:8a2e:0370:7334] (IPv6 uses a different syntax) • _test@[IPv6:2001:0db8:85a3:0000:0000:8a2e:0370:7334] (begin with underscore different syntax)
Valid email addresses with SMTPUTF8 • I❤️CHOCOLATE@example.com (
emoji are only allowed with SMTPUTF8)
Invalid email addresses • abc.example.com (no @ character) • a@b@c@example.com (only one @ is allowed outside quotation marks) • a"b(c)d,e:f;gi[j\k]l@example.com (none of the special characters in this local-part are allowed outside quotation marks) • just"not"right@example.com (quoted strings must be dot separated or be the only element making up the local-part) • this is"not\allowed@example.com (spaces, quotes, and backslashes may only exist when within quoted strings and preceded by a backslash) • this\ still\"not\\allowed@example.com (even if escaped (preceded by a backslash), spaces, quotes, and backslashes must still be contained by quotes) • 1234567890123456789012345678901234567890123456789012345678901234+x@example.com (local-part is longer than 64 characters) • i.like.underscores@but_they_are_not_allowed_in_this_part (underscore is not allowed in domain part) == Validation and verification ==