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 5,700 community submitted regex patterns...
10
15 upvotes, 5 downvotes (score 53.1%) (You must be signed in to vote)
Valid Telephone Number
ECMAScript (JavaScript)
This regex validates varying types of telephone numbers.
Submitted by
Adam Recvlohe
-
8 years ago
2015-12-09 01:04
6
7 upvotes, 1 downvotes (score 52.9%) (You must be signed in to vote)
TimezoneOffset
ECMAScript (JavaScript)
used to parse timezone in the format -08:00 or +05:30
Submitted by
Neha
-
9 years ago
2014-12-09 07:00
8
11 upvotes, 3 downvotes (score 52.4%) (You must be signed in to vote)
money: either 0 or 2 dp
ECMAScript (JavaScript)
no description available
Submitted by
anonymous
-
8 years ago
2015-11-18 19:34
107
601 upvotes, 494 downvotes (score 51.9%) (You must be signed in to vote)
trim
ECMAScript (JavaScript)
trim string
Submitted by
fp
-
10 years ago
2013-09-10 08:21
24
67 upvotes, 43 downvotes (score 51.6%) (You must be signed in to vote)
Quote Macthing with escape
ECMAScript (JavaScript)
Matches text within quotes (", ') and escapes the charecters.
Submitted by
Vihan Bhargava
-
8 years ago
2015-05-10 20:48
11
19 upvotes, 8 downvotes (score 51.5%) (You must be signed in to vote)
html color match: transparent, #fff, #123456, rgb, rgba, hsl, hsla
ECMAScript (JavaScript)
This may be useful or not to test whether a given string is a valid (more or less) html color value. It matches color values such as: #123 - short hex color value #123456 - hex color value rgb(255,255,0) - rgb color value rgba(255,255,0,1.0) - rgba color value hsl(360,100%,100%) - hsl color value...
Submitted by
grouch
-
9 years ago
2014-12-17 13:00
34
123 upvotes, 89 downvotes (score 51.3%) (You must be signed in to vote)
Google like regex
ECMAScript (JavaScript)
Attempts to mimic Google search box behavior, returning an array with the separated search strings (that keep the +/- indicator for following operations)
Submitted by
mettjus
-
9 years ago
2014-05-12 13:35
4
4 upvotes, 0 downvotes (score 51%) (You must be signed in to vote)
Typescript - /// <reference path="..."/> Expression
ECMAScript (JavaScript)
Finds Typescript's reference path syntax.
Submitted by
Lovelidge, Shawn
-
8 years ago
2015-09-08 22:26
4
4 upvotes, 0 downvotes (score 51%) (You must be signed in to vote)
find uncommented coffeescript console.logs
ECMAScript (JavaScript)
no description available
Submitted by
valiafetisov
-
8 years ago
2016-01-18 01:52
4
4 upvotes, 0 downvotes (score 51%) (You must be signed in to vote)
extract domain with port
ECMAScript (JavaScript)
no description available
Submitted by
yooresh
-
8 years ago
2016-02-18 08:29
4
4 upvotes, 0 downvotes (score 51%) (You must be signed in to vote)
Function Declaration / Expression
ECMAScript (JavaScript)
matches both function declarations and expressions in javascript. ex. function name () {...} || function () {}
Submitted by
Ja Superior
-
8 years ago
2016-03-09 09:13
4
4 upvotes, 0 downvotes (score 51%) (You must be signed in to vote)
UK Postcode
ECMAScript (JavaScript)
no description available
Submitted by
msyed
-
7 years ago
2016-04-04 13:37
4
4 upvotes, 0 downvotes (score 51%) (You must be signed in to vote)
Campos Decimais (pt_br)
ECMAScript (JavaScript)
Funciona para campos decimais para moeda nacional brasileira. Aceita números inteiros, separação por milhar e a separação decimal.
Submitted by
Murilo C. Cumerlatto
-
7 years ago
2016-07-21 20:52
4
4 upvotes, 0 downvotes (score 51%) (You must be signed in to vote)
CloudFlare
PCRE2 (PHP >=7.3)
Cloud Flare
Submitted by
anonymous
-
2 years ago
2021-06-29 16:27
4
4 upvotes, 0 downvotes (score 51%) (You must be signed in to vote)
Email
PCRE2 (PHP >=7.3)
email format control
Submitted by
ahmetbarut
-
2 years ago
2021-07-10 13:06
12
23 upvotes, 11 downvotes (score 50.8%) (You must be signed in to vote)
Username with "_" "-"
ECMAScript (JavaScript)
no description available
Submitted by
Gianvy
-
8 years ago
2015-10-16 15:44
31
142 upvotes, 111 downvotes (score 50%) (You must be signed in to vote)
Email address (most used)
ECMAScript (JavaScript)
Email address, most used cases
Submitted by
Jago
-
8 years ago
2015-07-01 09:32
7
10 upvotes, 3 downvotes (score 49.7%) (You must be signed in to vote)
Date and time format - ISO 8601
ECMAScript (JavaScript)
Matches ISO 8601 date formats
Submitted by
Ettienne
-
8 years ago
2016-02-03 08:21
6
8 upvotes, 2 downvotes (score 49%) (You must be signed in to vote)
Spanish DNI/NIE check fist pass
ECMAScript (JavaScript)
no description available
Submitted by
Rafael Casanova Morera
-
8 years ago
2015-09-27 22:27
6
8 upvotes, 2 downvotes (score 49%) (You must be signed in to vote)
Email
ECMAScript (JavaScript)
no description available
Submitted by
anonymous
-
7 years ago
2016-04-25 17:30
1
2
3
4
5
...
285
wip; 匹配malloc申请的内容和使用的不一致
1
1 upvotes, 0 downvotes (score 20.7%) (You must be signed in to vote)
Regular Expression
PCRE2 (PHP >=7.3)
/
(
\S
+
)
=
.
*
VOS_Malloc
\(
\S
+
,
.
*
\)
;
.
*
memset_s
\s
*
\(
[^
,
]
*
\1
[^
,
]
*
,
(
[^
,
]
+
)
,
[^
,
]
+
,
(
[^
,
]
+
)
\)
;
/
gms
Open regex in editor
Description
Loading markdown...
Submitted by
zyf
-
5 months ago
2023-05-13 06:43