Are email addresses case sensitive?

General Linux topics
Post Reply
Site Admin
Posts: 50
Joined: Sun Aug 08, 2021 7:49 am

Are email addresses case sensitive?

Post by admin »

I've read that by the standard first part of the e-mail is case sensitive, however, I've tried to send e-mail to,, and - it has arrived in each case.

How do mail servers handle usernames? Is it possible to miss with case and that message wouldn't be delivered? Is it really very important to use exactly the same letter case, as was written while registering when giving your e-mail address?


The standard mailbox naming convention is defined to be "local-part@domain"; contemporary usage permits a much broader set of applications than simple "user names". Consequently, and due to a long history of problems when intermediate hosts have attempted to optimize transport by modifying them, the local-part MUST be interpreted and assigned semantics only by the host specified in the domain part of the address.

So yes, the part before the "@" could be case-sensitive, since it is entirely under the control of the host system. In practice though, no widely used mail systems distinguish different addresses based on case.

The part after the @ sign however is the domain and according to RFC 1035, section 3.1,

"Name servers and resolvers must compare [domains] in a case-insensitive manner"

In short, you are safe to treat email addresses as case-insensitive.

'In short, you are safe to treat email addresses as case-insensitive.' I'd phrase it stronger: "you're unsafe to treat email-addresses as case-sensitive manner" Especially when checking for duplicates in user-databases, etc. –
Nov 16, 2013 at 23:00
I'd disagree with the conclusion. If you're looking for duplicates in a database - yes, a case insensitive match is probably the best way to go, but I've seen code where the email address is converted to lower case prior to sending. That's not a good idea, since there is a small chance it will not get delivered. So how you treat it depends on what the consequences of error are and what you're doing with the email addresses at that time (collating a list of unique addresses, sending an email, etc). –
Peter Bagnall
Sep 12, 2014 at 9:32
Does anyone know of a list of mail products that will (a) reject a when the user is valid, or (b) will allow two distinct mailboxes to be created: and –
Mar 4, 2015 at 3:48
I work at a large company and there is another person with the same first and last name. I discovered today that his local-part differs from mine only in capitalization. This has been working properly, so I was surprised to see "no widely used mail systems distinguish different addresses based on case". We use MS Exchange which I would call "widely used". –
Matthew James Briggs
Nov 24, 2015 at 20:14
RFC 5321 2.4. General Syntax Principles and Transaction Model - SMTP implementations MUST take care to preserve the case of mailbox local-parts. In particular, for some hosts, the user "smith" is different from the user "Smith". Mailbox domains follow normal DNS rules and are hence not case sensitive. –
Post Reply