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

Please support RegExLib Sponsors

Hosting Spotlight

Sponsors

Browse Expressions by Category

38 regular expressions found in this category!

Expressions in category: Email

Change page:   |    Displaying page 2 of 2 pages; Items 21 to 38
Title Test Details Pattern Title
Expression
^(?:[a-zA-Z0-9_'^&/+-])+(?:\.(?:[a-zA-Z0-9_'^&/+-])+)*@(?:(?:\[?(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?))\.){3}(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\]?)|(?:[a-zA-Z0-9-]+\.)+(?:[a-zA-Z]){2,}\.?)$
Description
this will validate most legal email addresses, even allows for some discouraged but perfectly legal characters in local part; allows IP domains with optional []; keeps final tld at a minmum of 2 chars; non capturing groups for efficiency
Matches
you.me.hello@somewhere.else.cc | joe_smith@here.com. | me@[24.111.232.1]
Non-Matches
.me.you@here.com | .murat@62.59.114.103.nl | test_case@here*555%there.com
Author Rating: The rating for this expression. Micah Duke
Title Test Details Pattern Title
Expression
(?<email>(?![ ])(\w|[.])*@(\w|[.])*)
Description
E-mail addresses matcher
Matches
mpgrewal@rediffmail.com
Non-Matches
arnoldschwarz
Author Rating: The rating for this expression. Manpreet Grewal
Title Test Details Pattern Title
Expression
^[a-z0-9][a-z0-9_\.-]{0,}[a-z0-9]@[a-z0-9][a-z0-9_\.-]{0,}[a-z0-9][\.][a-z0-9]{2,4}$
Description
for validate a email, but with this regex it 's possible : a._-z@a_.....____---.com
Matches
az@er.tr | a_zer-ty@az.er.ty | 123-456_789.0@1.2.3iuyt.azer
Non-Matches
a@a.a | a.@_1.com | azerty_@domain-com
Author Rating: The rating for this expression. Laurent J
Title Test Details Pattern Title
Expression
^[\w-]+(?:\.[\w-]+)*@(?:[\w-]+\.)+[a-zA-Z]{2,7}$
Description
Matches 99.99% of e-mail addresses (excludes IP e-mails, which are rarely used). The {2,7} at the end leaves space for top level domains as short as .ca but leaves room for new ones like .museum, etc. The ?: notation is a perl non-capturing notation, and can be removed safely for non-perl-compatible languages. See also email.
Matches
joe.tillis@unit.army.mil | jack_rabbit@slims.com | foo99@foo.co.uk
Non-Matches
find_the_mistake.@foo.org | .prefix.@some.net
Author Rating: The rating for this expression. J. Washam
Title Test Details Pattern Title
Expression
^[A-Za-z0-9](([_\.\-]?[a-zA-Z0-9]+)*)@([A-Za-z0-9]+)(([\.\-]?[a-zA-Z0-9]+)*)\.([A-Za-z]{2,})$
Description
Matches
mahesh@yahoo.com | mahehs_t@yahoo.com
Non-Matches
dot_dot@dot_i.com
Author Rating: The rating for this expression. mahesh mandhare
Title Test Details Pattern Title
Expression
^([0-9a-zA-Z]([-.\w]*[0-9a-zA-Z])*@(([0-9a-zA-Z])+([-\w]*[0-9a-zA-Z])*\.)+[a-zA-Z]{2,9})$
Description
Email validation based on Rob Eberhardt's (Thanks, Rob!) email expression, but allows single letter subdomains...
Matches
bob@smith.com | bob@j.smith.museum | bob.smith@a-1.smith.com
Non-Matches
bob@.com | bob@-a.smith.com
Author Rating: The rating for this expression. Shaune Stark
Title Test Details Pattern Title
Expression
^([a-zA-Z0-9_\-\.]+)@([a-zA-Z0-9_\-\.]+)\.([a-zA-Z]{2,5})$
Description
Easy expression that checks for valid email addresses.
Matches
somthing@someserver.com | firstname.lastname@mailserver.domain.com | username-something@some-server.
Non-Matches
username@someserver.domain.c | somename@server.domain-com | someone@something.se_eo
Author Rating: Not yet rated. Zrekam makerZ
Title Test Details Pattern Title
Expression
^((([a-zA-Z\'\.\-]+)?)((,\s*([a-zA-Z]+))?)|([A-Za-z0-9](([_\.\-]?[a-zA-Z0-9]+)*)@([A-Za-z0-9]+)(([\.\-]?[a-zA-Z0-9]+)*)\.([A-Za-z]{2,})))(;{1}(((([a-zA-Z\'\.\-]+){1})((,\s*([a-zA-Z]+))?))|([A-Za-z0-9](([_\.\-]?[a-zA-Z0-9]+)*)@([A-Za-z0-9]+)(([\.\-]?[a-zA-Z0-9]+)*)\.([A-Za-z]{2,})){1}))*$
Description
This regular expression matches a series of names and/or email addresses much like you would do in Outlook's To field (e.g. To: wrohrbach@carlson.com;miles, er;roemer;lagrander, nitra). The first entry must be a name (in the form of last name followed by a comma and first name) or an email address. The following entries are a semicolon followed by one name or email address. The comma and first name are optional components of the name part.
Matches
rohrbach | rohrbach, wi | rohrbach, wi;roemer;emiles@carlson.com;lagrander, ni
Non-Matches
rohrbach;miles; | rohrbach, wa; | wrohrbach@carlson.com;miles;;
Author Rating: Not yet rated. William Rohrbach
Title Test Details Pattern Title
Expression
^\W{0,5}[Rr]e:\W[a-zA-Z0-9]{1,10},\W[a-z]{1,10}\W[a-z]{1,10}\W[a-z]{1,10}
Description
Simple email subject line matching. This regex matches those really annoying emails that begin with 0-5 spaces, followed by a fake reply, contain a random string of letters (usually CAPITALIZED) from 1-10 characters long followed by a comma, and then followed by three lower-case words each from 1-10 characters long. In my experience, the 3 trailing words are always lower-case. the words make begin with, contain, or end in common punctuation marks.
Matches
re: ASDFG, hours among lifestyle | Re: ASD34SSDF, i can't believe | Re: VZWENKS, the coffin brogade
Non-Matches
re: ASDFGASFDASDF, Hours among lifestyle | Re: ASD34SSDF, I can't believe it's true
Author Rating: Not yet rated. Joseph Lundgren
Title Test Details Pattern Title
Expression
^.+@[^\.].*\.[a-z]{2,}$
Description
Most email validation regexps are outdated and ignore the fact that domain names can contain any foreign character these days, as well as the fact that anything before @ is acceptable. The only roman alphabet restriction is in the TLD, which for a long time has been more than 2 or 3 chars (.museum, .aero, .info). The only dot restriction is that . cannot be placed directly after @. This pattern captures any valid, reallife email adress.
Matches
whatever@somewhere.museum | foreignchars@myforeigncharsdomain.nu | me+mysomething@mydomain.com
Non-Matches
a@b.c | me@.my.com | a@b.comFOREIGNCHAR
Author Rating: Not yet rated. Thor Larholm
Title Test Details Pattern Title
Expression
^((?:(?:(?:\w[\.\-\+]?)*)\w)+)\@((?:(?:(?:\w[\.\-\+]?){0,62})\w)+)\.(\w{2,6})$
Description
Not a 100% email validation. It doesn't work with IP-Adresses, but it's good for most common cases. At least I hope so.
Matches
a-b-c@d-e-f.com | a@b.ce | Me@my.museum
Non-Matches
abc@def.g | a--b@c--d.fe | -abc@-def-.def
Author Rating: Not yet rated. Sebastian Hiller
Title Test Details Pattern Title
Expression
\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*([,;]\s*\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*)*
Description
Validates 1 or more email addresses. Email addresses can be delimited with either comma or semicolon. White space is allowed after delimiter, but not necessary. I needed this to allow my users to specify multiple email addresses if they choose to do so.
Matches
lewis@moten.com | lewis@moten.com, me@lewismoten.com | lewis@moten.com;me@lewismoten.com
Non-Matches
lewis@@moten.com
Author Rating: Not yet rated. Lewis Moten
Title Test Details Pattern Title
Expression
^((?&lt;DRIVE&gt;[a-z]:)|(\\\\(?&lt;SERVER&gt;[0-9]*[a-z\-][a-z0-9\-]*)\\(?&lt;VOLUME&gt;[^\.\x01-\x1F\\&quot;&quot;\*\?&lt;&gt;:|\\/][^\x01-\x1F\\&quot;&quot;\*\?|&gt;&lt;:\\/]*)))?(?&lt;FOLDERS&gt;(?&lt;FOLDER1&gt;(\.|(\.\.)|([^\.\x01-\x1F\\&quot;&quot;\*\?|&gt;&lt;:\\/][^\x01-\x1F\\&quot;&quot;\*\?&lt;&gt;:|\\/]*)))?(?&lt;FOLDERm&gt;[\\/](\.|(\.\.)|([^\.\x01-\x1F\\&quot;&quot;\*\?|&gt;&lt;:\\/][^\x01-\x1F\\&quot;&quot;\*\?&lt;&gt;:|\\/]*)))*)?[\\/]?$
Description
Verify &quot;well formed-ness&quot; of DOS or UNC paths. Passed over 170 NUnit test, (took 3 complete rewrites) Components of a path: DRIVE:=[a-z]: SERVER:=[0-9]*[a-z\-][a-z0-9\-]* FNAME:=[^\.\x01-\x1F\\&quot;&quot;\*\?&lt;&gt;:|\\/][^\x01-\x1F\\&quot;&quot;\*\?&lt;&gt;:|\\/]* VOLUME:=FNAME UNC:=\\SERVER\VOLUME ROOT:=(DRIVE|UNC) FOLDER:=.|..|FNAME FOLDERS:=FOLDER?([\]FOLDER)*[\]? PATH:=^ROOT?FOLDERS?$
Matches
his is a very 'long' folder\that is.part of 2 folders. | b\c\..\x. | \\Dads\Mp3\FileName1\.\TestDir2
Non-Matches
\\1.dads\C | \. folder\ | .ext
Author Rating: Not yet rated. Tristen Fielding
Title Test Details Pattern Title
Expression
^([\w\-\.]+)@((\[([0-9]{1,3}\.){3}[0-9]{1,3}\])|(([\w\-]+\.)+)([a-zA-Z]{2,4}))$
Description
Expression 1 of 2 used to check email address syntax.
Matches
bob@somewhere.com | bob.jones@[1.1.1.1] | bob@a.b.c.d.info
Non-Matches
bob@com | bob.jones@some.where | bob@1.1.1.123
Author Rating: Not yet rated. David Lott
Title Test Details Pattern Title
Expression
^(([-\w \.]+)|(&quot;&quot;[-\w \.]+&quot;&quot;) )?&lt;([\w\-\.]+)@((\[([0-9]{1,3}\.){3}[0-9]{1,3}\])|(([\w\-]+\.)+)([a-zA-Z]{2,4}))&gt;$
Description
Expression 2 or 2 for matching email address syntax. This one matches the &lt;angle bracket syntax&gt;.
Matches
&lt;ab@cd.ef&gt; | bob A. jones &lt;ab@cd.ef&gt; | bob A. jones &lt;ab@[1.1.1.111]&gt;
Non-Matches
ab@cd.ef | &quot;bob A. jones &lt;ab@cd.ef&gt; | bob A. jones &lt;ab@1.1.1.111&gt;
Author Rating: Not yet rated. David Lott
Title Test Details Pattern Title
Expression
\w+[\w-\.]*\@\w+((-\w+)|(\w*))\.[a-z]{2,3}$|^([0-9a-zA-Z'\.]{3,40})\*|([0-9a-zA-Z'\.]+)@([0-9a-zA-Z']+)\.([0-9a-zA-Z']+)$|([0-9a-zA-Z'\.]+)@([0-9a-zA-Z']+)\*+$|^$
Description
This regular expression is for admitting wild card searches on Emails the wild card character is * and in my case will only allow to do the search when the * is place after the first 3 alphanumeric characters. If you need to modify this behavior change the {3,40} to {n,m} where n is how many characters before the * and m is the total number if characters.
Matches
jdh* | jss.js* | juan.sk@micro.com
Non-Matches
j* | js*
Author Rating: Not yet rated. Julio de la Yncera
Title Test Details Pattern Title
Expression
^[\w-]+(\.[\w-]+)*@([a-z0-9-]+(\.[a-z0-9-]+)*?\.[a-z]{2,6}|(\d{1,3}\.){3}\d{1,3})(:\d{4})?$
Description
Matches a valid email address including ip's which are rarely used. Allows for a-z0-9_.- in the username, but not ending in a full stop i.e user.@domain.com is invalid and a-z0-9- as the optional sub domain(s) with domain name and a 2-7 char (a-z) tld allowing for short tld's like ca and new ones like museum.
Matches
username@domain.com | u-s_e.r1@s-ub2.domain-name.museum:8080 | user_name@123.123.123.12
Non-Matches
user@domain | user@domain.c | user.@domain.com
Author Rating: Not yet rated. nick bennett
Title Test Details Pattern Title
Expression
^[\w-\.]+@([\w-]+\.)+[\w-]{2,4}$
Description
This expression matches email addresses, and checks that they are of the proper form. It checks to ensure the top level domain is between 2 and 4 characters long, but does not check the specific domain against a list (especially since there are so many of them now).
Matches
joe@aol.com | joe@wrox.co.uk | joe@domain.info
Non-Matches
a@b | notanemail | joe@@.
Author Rating: Not yet rated. Steven Smith
Change page:   |    Displaying page 2 of 2 pages; Items 21 to 38

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