Regular
Expressions
101
Please wait while the app is loading...
Please enable JavaScript to use this web application.
Regular
Expressions
101
@regex101
Donate
Sponsor
Contact
Bug Reports & Feedback
Wiki
What's new?
What's new?
Loading content...
Close
Regex Editor
Regex Editor
Regex Library
Regex Library
Account
Account
Regex Quiz
Regex Quiz
Settings
Settings
Live Help
Live Help
Order By
Most Recent
Most Points
Fewest Points
Filter by Flavor
PCRE2
PCRE
ECMAScript
Python
Golang
Java
.NET
Sponsors
All your environment variables, in one place
Library entries
Search library
483
1566 upvotes, 1083 downvotes (59% like it) (You must be signed in to vote)
pcre
regex101.com id grabber
grabs the ID for the regex101.com permalink to code
Submitted by
chris mccoy
-
9 years ago
234
715 upvotes, 481 downvotes (60% like it) (You must be signed in to vote)
pcre
Matching email addresses per RFC5322
The BNF rules from RFC 5322 transformed to PCRE by Nikita Popov and described in the post http://nikic.github.io/2012/06/15/The-true-power-of-regular-expressions.html.
Submitted by
Michael Musson
-
10 years ago
51
191 upvotes, 140 downvotes (58% like it) (You must be signed in to vote)
pcre
Disorted Email Addresses
Matches distorted email addresses and converts them back to real ones.
Submitted by
dislick
-
10 years ago
40
325 upvotes, 285 downvotes (53% like it) (You must be signed in to vote)
pcre
URL regexp
A quite neat regular expression for URLs, e-mails..., I found on Matthew O'Riordan's blog.
Submitted by
Matthew O'Riordan
-
10 years ago
37
236 upvotes, 199 downvotes (54% like it) (You must be signed in to vote)
pcre
http://
no description available
Submitted by
Mitus M.
-
9 years ago
32
78 upvotes, 46 downvotes (63% like it) (You must be signed in to vote)
pcre
ninite
no description available
Submitted by
peek
-
8 years ago
28
69 upvotes, 41 downvotes (63% like it) (You must be signed in to vote)
pcre
Wrap long string to spec length
no description available
Submitted by
fullpipe
-
10 years ago
28
77 upvotes, 49 downvotes (61% like it) (You must be signed in to vote)
pcre
CSV line parsing
Captures all fields from a CSV file's line. Can be customized with user-defined field separator and protecting character.
Submitted by
Various
-
9 years ago
26
91 upvotes, 65 downvotes (58% like it) (You must be signed in to vote)
pcre
match valid JSON
Matches any valid JSON object, matches recursively. Passes all JSON test cases I found.
Submitted by
Mateon1
-
9 years ago
23
88 upvotes, 65 downvotes (58% like it) (You must be signed in to vote)
pcre
userName
1-15 alphanumeric login name
Submitted by
gsanchezc
-
8 years ago
22
59 upvotes, 37 downvotes (61% like it) (You must be signed in to vote)
pcre
UK Postcode Checker
Checks for valid UK/British postcodes. There was another on here that had for some reason been upvoted, but it was actually incorrect as it worked on none of my valid own postcodes! Namely that it assumed two letters and a number (BS3) when you can have variations (M20). Allows for an optional spac...
Submitted by
MaffooBristol
-
9 years ago
18
21 upvotes, 3 downvotes (88% like it) (You must be signed in to vote)
pcre
Parsing browser User Agents
From a (fairly large) list of User Agent strings, extract the OS, Browser, and Device Type.
Submitted by
OnlineCop
-
8 years ago
18
31 upvotes, 13 downvotes (70% like it) (You must be signed in to vote)
pcre
Date Regex(DD/MM/yyyy)
no description available
Submitted by
alcaamado
-
8 years ago
17
309 upvotes, 292 downvotes (51% like it) (You must be signed in to vote)
pcre
Date: DD-MM-YYYY hh:mm:ss
Validate and capture dateTime parts, includes validation for leap years, range 1000-2999. Fixed bug
Submitted by
Ka.
-
10 years ago
17
118 upvotes, 101 downvotes (54% like it) (You must be signed in to vote)
pcre
Email validation
no description available
Submitted by
tutsplus.com
-
9 years ago
17
31 upvotes, 14 downvotes (69% like it) (You must be signed in to vote)
pcre
Capture comma separated numbers
Capture comma separated numbers, no matter if there are spaces before or after the commas.
Submitted by
Fernando Nunes
-
8 years ago
17
34 upvotes, 17 downvotes (67% like it) (You must be signed in to vote)
pcre
Between tags content
no description available
Submitted by
AgustÃn Bouillet
-
8 years ago
16
101 upvotes, 85 downvotes (54% like it) (You must be signed in to vote)
pcre
Alphanumeric Regex
no description available
Submitted by
Deepan
-
8 years ago
16
29 upvotes, 13 downvotes (69% like it) (You must be signed in to vote)
pcre
IPv4
no description available
Submitted by
robwa
-
7 years ago
16
17 upvotes, 1 downvotes (94% like it) (You must be signed in to vote)
pcre
Cron schedule
Validate cron lines (even the ones commented out)
Submitted by
anonymous
-
7 years ago
1
2
3
4
...
572
aa
Vote
1
1 upvotes, 0 downvotes (100% like it) (You must be signed in to vote)
Regular Expression
pcre
/
[
0
-
9
]
{1,3}
[
\s
]
*
?
[
_|.,:;
]
[
\s
]
*
?
[
0
-
9
]
{1,3}
[
\s
]
*
?
[
_|.,:;
]
[
\s
]
*
?
[
0
-
9
]
{1,3}
[
\s
]
*
?
[
_|.,:;
]
[
\s
]
*
?
[
0
-
9
]
{1,3}
[
\s
]
*
?
:
[
\s
]
*
?
[
0
-
9
]
{3,6}
/
Open regex in editor
Description
Loading markdown...
Submitted by
aaa
- 8 years ago