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 11,660 community submitted regex patterns...
1
1 upvotes, 0 downvotes (score 20.7%) (You must be signed in to vote)
tesdsa
PCRE (PHP <7.3)
dsadsadsadsa
Submitted by
dasdasdsa
-
9 years ago
2014-07-22 15:06
1
5 upvotes, 4 downvotes (score 26.7%) (You must be signed in to vote)
HTML color search
PCRE (PHP <7.3)
Searches for hex colors in HTML code.
Submitted by
Barlean
-
9 years ago
2014-07-22 12:35
2
7 upvotes, 5 downvotes (score 32%) (You must be signed in to vote)
named group sample
PCRE (PHP <7.3)
no description available
Submitted by
anonymous
-
9 years ago
2014-07-21 23:39
1
1 upvotes, 0 downvotes (score 20.7%) (You must be signed in to vote)
background-image URL
PCRE (PHP <7.3)
regex to fetch the URL of the background-image CSS-Propertie
Submitted by
Mutator
-
9 years ago
2014-07-21 10:51
-2
1 upvotes, 3 downvotes (score 4.6%) (You must be signed in to vote)
Date YYYYMMDD
PCRE (PHP <7.3)
Date in format YYYYMMDD Year between [1900-2099] No leap year check but month 02 is limited to 29 days.
Submitted by
Ahmed Z
-
9 years ago
2014-07-19 20:12
0
1 upvotes, 1 downvotes (score 9.5%) (You must be signed in to vote)
Find all list items
PCRE (PHP <7.3)
I need to find the fastest expression to get all the list items inside a an put the items inside an array. input: xxx ...
Submitted by
Sonny
-
9 years ago
2014-07-17 16:32
1
1 upvotes, 0 downvotes (score 20.7%) (You must be signed in to vote)
Reading only the "=" symbol
PCRE (PHP <7.3)
The pattern should match only the "=" symbols with in the html content other than the HTML attributes. i.e if we have Sample head This is a test a=b=c=d or a = b = c The pattern should match only "=" outside the html tags
Submitted by
Dilip
-
9 years ago
2014-07-17 09:01
1
3 upvotes, 2 downvotes (score 23.1%) (You must be signed in to vote)
question regarding "split" like regex group
PCRE (PHP <7.3)
dear all, i am a regex beginner, so please be gentle :) we have lines of log contents delimited by a pipe char. is it possible to fetch the content between the 5th and the 6th delimiter, ignoring the values in between? example log line:...
Submitted by
regexBeginner
-
9 years ago
2014-07-16 17:46
1
1 upvotes, 0 downvotes (score 20.7%) (You must be signed in to vote)
regex int
PCRE (PHP <7.3)
var pattern='/^0-9{0,6}$/'; /* int match 9 digit */ /** ^ starting point 1st [0-9] number should be start between 0 to 9 2nd [0-9] number should be end between 0 to 9 3nd {0-6} number length should be exact 6 digit...
Submitted by
sudhir k gupta
-
9 years ago
2014-07-16 12:37
0
1 upvotes, 1 downvotes (score 9.5%) (You must be signed in to vote)
split on dollar sign
PCRE (PHP <7.3)
no description available
Submitted by
anonymous
-
9 years ago
2014-07-15 18:53
1
3 upvotes, 2 downvotes (score 23.1%) (You must be signed in to vote)
include case
PCRE (PHP <7.3)
How to include the matched cases in the result?
Submitted by
anonymous
-
9 years ago
2014-07-14 14:37
1
1 upvotes, 0 downvotes (score 20.7%) (You must be signed in to vote)
test
PCRE (PHP <7.3)
no description available
Submitted by
anonymous
-
9 years ago
2014-07-10 18:08
1
1 upvotes, 0 downvotes (score 20.7%) (You must be signed in to vote)
Usability request
PCRE (PHP <7.3)
implement vi keys PLEASE
Submitted by
maurice.sprauge@gmail.com
-
9 years ago
2014-07-09 05:42
1
1 upvotes, 0 downvotes (score 20.7%) (You must be signed in to vote)
stripping annotations from pre-NewsML transcripts
PCRE (PHP <7.3)
no description available
Submitted by
Brian D'Astous
-
9 years ago
2014-07-02 17:01
0
3 upvotes, 3 downvotes (score 18.8%) (You must be signed in to vote)
Replace one or more 'br' tags with a single space.
PCRE (PHP <7.3)
no description available
Submitted by
James Furey
-
9 years ago
2014-07-02 16:33
0
41 upvotes, 41 downvotes (score 39.4%) (You must be signed in to vote)
URL matching
PCRE (PHP <7.3)
Complete url matching with storage of various parameters
Submitted by
hjpotter92
-
9 years ago
2014-07-02 06:34
0
1 upvotes, 1 downvotes (score 9.5%) (You must be signed in to vote)
Removes comments from css files
PCRE (PHP <7.3)
This regexp removes comments from css (text/css) files (multiline)
Submitted by
Ray (alrays@yandex.ru)
-
9 years ago
2014-06-26 07:52
1
1 upvotes, 0 downvotes (score 20.7%) (You must be signed in to vote)
youtube links in wp/embed context
PCRE (PHP <7.3)
no description available
Submitted by
anonymous
-
9 years ago
2014-06-25 22:13
0
1 upvotes, 1 downvotes (score 9.5%) (You must be signed in to vote)
google result li item
PCRE (PHP <7.3)
Trying to output http://www.fs.usda.gov/malheur or thereabouts
Submitted by
ape
-
9 years ago
2014-06-24 18:19
4
20 upvotes, 16 downvotes (score 39.6%) (You must be signed in to vote)
Element's Attribute Value in XML (simple)
PCRE (PHP <7.3)
Simple regular expression for extracting attribute value of the element in XML-string. Attribute value should be in quotes.
Submitted by
Nikita Danilov
-
9 years ago
2014-06-24 11:29
1
...
569
570
571
572
573
574
575
...
583
Parse drupal version info from filename
1
1 upvotes, 0 downvotes (score 20.7%) (You must be signed in to vote)
Regular Expression
PCRE (PHP <7.3)
/
^
(?<project>
\w
+
)
-
(?<core>
\d
+
\.
x
)
-
(?<major>
\d
+
)
\.
(?<patch>
[
\d
x
]
+
)
[
-
\.
]
?
(?<extra>
[^
\.
]
+
)?
\.
(
tar
\.
gz
|
tgz
)
$
/
mg
Open regex in editor
Description
Loading markdown...
Submitted by
Jason Smith
-
10 years ago
2014-03-18 15:02