RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Regular Expression Details

Title Test Find Pattern Title
Expression
^[\w\.=-]+@[\w\.-]+\.[\w]{2,3}$
Description
Much simpler email expression. This one forces a length of 2 or 3, which fits current specs, but you may need to alter the end as this one allows all numerals on the .COM section.
Matches
Non-Matches
word | word@ | @word
Author Rating: The rating for this expression. Gregory Beamer
Source
Your Rating
Bad Good

Enter New Comment

Title

Name

Comment

Spammers suck - we apologize. Please enter the text shown below to enable your comment (not case sensitive - try as many times as you need to if the first ones are too hard):

Existing User Comments

Title: Doesn't account for all domains
Name: Al
Date: 4/14/2022 2:13:25 PM
Comment:
This doesn't account for 4-letter domains


Title: Many false negatives!
Name: JJ
Date: 7/2/2009 6:02:17 PM
Comment:
Too many things wrong with this one to consider using it. For starters, top-level domains greater than 3 chars, such as .store and .museum, will be failed.


Title: only it doesn't work
Name: pinetree
Date: 6/16/2003 3:59:24 PM
Comment:
Except that per RFC 822 (http://www.w3.org/Protocols/rfc822/Overview.html), the following email addresses are valid but would be trapped as invalid by this code. Specifically, look at Appendix A (http://www.w3.org/Protocols/rfc822/Overview.html#z10), section A.3.3.<br><br> "Some Silly User"@example.com<br> Another'[email protected]<br> Yet/Another/Wacky/[email protected]


Copyright © 2001-2024, RegexAdvice.com | ASP.NET Tutorials