Please enable JavaScript to use this web application.
Regular
Expressions
101
Social
Social
Join the Discord community!
Follow me on twitter!
Send me an email
Donate
Donate
Donate through Paypal
Become a Github Sponsor
Info
Info
Find out what's new!
RegEx101 Wiki
Report bugs or make suggestions
What's new?
Loading content...
Close
Regex Editor
Regex Editor
Community Patterns
Community Patterns
Account
Account
Regex Quiz
Regex Quiz
Settings
Settings
Live Help
Live Help
Get help on Discord
Get help on IRC
Order By
Most Recent
Highest Score
Lowest Score
Most upvotes
Most downvotes
Filter by Flavor
PCRE2 (PHP >=7.3)
PCRE (PHP <7.3)
ECMAScript (JavaScript)
Python
Golang
Java 8
.NET (C#)
Rust
Sponsors
Community Patterns
Search among 17,260 community submitted regex patterns...
7
8 upvotes, 1 downvotes (score 56.5%) (You must be signed in to vote)
validate US (5 & 9 digit) ZipCodes and CA PostalCodes
PCRE (PHP <7.3)
no description available
Submitted by
anonymous
-
8 years ago
2015-05-15 18:00
7
8 upvotes, 1 downvotes (score 56.5%) (You must be signed in to vote)
simple email
ECMAScript (JavaScript)
no description available
Submitted by
anonymous
-
8 years ago
2015-06-11 01:12
7
8 upvotes, 1 downvotes (score 56.5%) (You must be signed in to vote)
Extract currency with currency symbol if present
ECMAScript (JavaScript)
Extracts values of the form £nnn,nnn.nn or $nnn.nnn from text
Submitted by
Simon Gardner
-
8 years ago
2015-09-11 11:35
7
8 upvotes, 1 downvotes (score 56.5%) (You must be signed in to vote)
Remove Widows (PHP)
PCRE (PHP <7.3)
Adds a non-breaking space between the last two words of sentences
Submitted by
herkulano
-
8 years ago
2015-09-13 13:44
72
410 upvotes, 338 downvotes (score 56.4%) (You must be signed in to vote)
Regex for telephone numbers all over the world
Recommended
This entry has been specifically selected by our team to be a great submission
ECMAScript (JavaScript)
Detects most of the phone numbers all over the world
Submitted by
Aditya Joshi
-
9 years ago
2014-04-08 07:58
36
77 upvotes, 41 downvotes (score 56.3%) (You must be signed in to vote)
IP Address validator
ECMAScript (JavaScript)
Validates IPv4 IP Address
Submitted by
krzysp
-
8 years ago
2015-06-18 12:52
4
4 upvotes, 0 downvotes (score 56.1%) (You must be signed in to vote)
semver
Recommended
This entry has been specifically selected by our team to be a great submission
PCRE (PHP <7.3)
Semantic Versioning regex pattern according to Tom Preston-Werner http://semver.org/ https://github.com/mojombo/semver/blob/master/semver.md First version of this regex follows semver 2.0.0....
Submitted by
@gvlx <Gerardo Lisboa>
-
9 years ago
2014-10-03 18:53
18
31 upvotes, 13 downvotes (score 55.8%) (You must be signed in to vote)
Date Regex(DD/MM/yyyy)
PCRE (PHP <7.3)
no description available
Submitted by
alcaamado
-
8 years ago
2015-08-26 06:25
15
25 upvotes, 10 downvotes (score 54.9%) (You must be signed in to vote)
Hashtag
ECMAScript (JavaScript)
The secret of the Twitterverse.
Submitted by
Joogl
-
9 years ago
2014-10-05 17:14
11
16 upvotes, 5 downvotes (score 54.9%) (You must be signed in to vote)
Codice fiscale
PCRE (PHP <7.3)
Check "codice fiscale"
Submitted by
Luca
-
8 years ago
2015-08-19 10:43
11
16 upvotes, 5 downvotes (score 54.9%) (You must be signed in to vote)
Full url parse, domain, path, params
ECMAScript (JavaScript)
no description available
Submitted by
anonymous
-
8 years ago
2015-08-25 20:54
9
12 upvotes, 3 downvotes (score 54.8%) (You must be signed in to vote)
English date in "dd mmmm yyyy" format
Python
Parse an English date following the "dd mmmm yyyy" format.
Submitted by
Tantale
-
8 years ago
2015-05-18 19:41
9
12 upvotes, 3 downvotes (score 54.8%) (You must be signed in to vote)
Letters, numbers and blank space
PCRE (PHP <7.3)
The following regular expression matches only letter a-z A-Z numbers 0-9 and a blank space for a given string.
Submitted by
Jordan Raychev
-
8 years ago
2016-01-04 17:31
17
31 upvotes, 14 downvotes (score 54.3%) (You must be signed in to vote)
Capture comma separated numbers
PCRE (PHP <7.3)
Capture comma separated numbers, no matter if there are spaces before or after the commas.
Submitted by
Fernando Nunes
-
8 years ago
2015-07-19 01:57
86
297 upvotes, 211 downvotes (score 54.1%) (You must be signed in to vote)
Password Validation
ECMAScript (JavaScript)
Checks that a password has a minimum of 6 characters, at least 1 uppercase letter, 1 lowercase letter, and 1 number with no spaces.
Submitted by
Christian Klemp
-
8 years ago
2015-07-08 18:46
16
29 upvotes, 13 downvotes (score 54%) (You must be signed in to vote)
IPv4
PCRE (PHP <7.3)
no description available
Submitted by
robwa
-
8 years ago
2015-12-17 08:14
31
77 upvotes, 46 downvotes (score 53.8%) (You must be signed in to vote)
ninite
PCRE (PHP <7.3)
no description available
Submitted by
peek
-
8 years ago
2015-09-29 11:28
29
70 upvotes, 41 downvotes (score 53.8%) (You must be signed in to vote)
Wrap long string to spec length
PCRE (PHP <7.3)
no description available
Submitted by
fullpipe
-
10 years ago
2013-07-21 20:34
11
17 upvotes, 6 downvotes (score 53.5%) (You must be signed in to vote)
find all link(<a>) tags expect your links in href attribute
ECMAScript (JavaScript)
YourLink - not found AnotherLink - found
Submitted by
KoT
-
8 years ago
2015-07-29 11:09
10
15 upvotes, 5 downvotes (score 53.1%) (You must be signed in to vote)
Just validate one sequence of
PCRE (PHP <7.3)
sdfs sdfs FLBREV00022230 dsfsdfs sdfsf FLBREV00022234 In this case is false
Submitted by
Fiipe
-
9 years ago
2014-10-23 13:22
1
2
3
4
5
6
...
863
Replace namespaces in xpath with local-name
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Regular Expression
.NET (C#)
@"
(?<=
(
/
|
^
)
)
(
(
(
/
|
^
)
|
(
\w
*
:
)
)
(?<node>
.
*
?
)
)
(?=
/
|
$
)
"
gm
Open regex in editor
Description
Loading markdown...
Submitted by
pvlzh
-
4 months ago
2023-05-23 08:29