Please enable JavaScript to use this web application.
Regular
Expressions
101
Social
Donate
Info
Regex Editor
Community Patterns
Account
Regex Quiz
Settings
Order By
Most Recent
Most upvotes
Most downvotes
Highest Score
Lowest Score
Filter by Flavor
PCRE2 (PHP >=7.3)
PCRE (PHP <7.3)
ECMAScript (JavaScript)
Python
Golang
Java 8
.NET 7.0 (C#)
Rust
Sponsors
There are currently no sponsors.
Become a sponsor today!
Community Patterns
Search among 18,040 community submitted regex patterns...
1
Match on Valid IP
PCRE (PHP <7.3)
Match on VALID IP address anywhere in string.
Submitted by
KyleV
-
7 years ago
1
Match on phone number in any standard format
PCRE (PHP <7.3)
Match on a phone number in ANY standard phone number format.
Submitted by
KyleV
-
7 years ago
1
SIREN
PCRE (PHP <7.3)
SIREN for french business register number
Submitted by
Maxime
-
7 years ago
1
SIRET
PCRE (PHP <7.3)
Business register number for France SIRET
Submitted by
Maxime
-
7 years ago
1
RNA
PCRE (PHP <7.3)
French association register number RNA
Submitted by
Maxime
-
7 years ago
1
Word filter
ECMAScript (JavaScript)
This regex matches up with the word rape, even if accent marks are used.
Submitted by
Ethan Lawrence
-
7 years ago
1
Match HTML img elements with URL source
PCRE (PHP <7.3)
Matches all img tags that have a URL for the src attribute. Useful for updating all those links in your email templates, or where ever your using the \ tag
Submitted by
Doom87er
-
7 years ago
1
Meetup Event URL
ECMAScript (JavaScript)
Allowed URL patterns for Meetup.com events
Submitted by
anonymous
-
7 years ago
1
Replace for CSS
PCRE (PHP <7.3)
no description available
Submitted by
anonymous
-
7 years ago
1
Check if string matches a valid CSS color (hex, rgb, rgba, hsl, hsla)
ECMAScript (JavaScript)
no description available
Submitted by
Ioannis Potouridis
-
7 years ago
1
Regex to group output of $(ip addr) interface
Python
For this task, I did not need inet6 (IPv6 stuff), so I left it out. The regex in its current state does not allow for that to be included without manually adding the entire second part
Submitted by
anonymous
-
7 years ago
1
Get SQL FROM
PCRE (PHP <7.3)
SELECT * FROM wp_users WHERE user_login = 'username'
Submitted by
Lars Jansen
-
7 years ago
1
IPV4 regex
PCRE (PHP <7.3)
no description available
Submitted by
anonymous
-
7 years ago
1
toby regex
PCRE (PHP <7.3)
no description available
Submitted by
anonymous
-
6 years ago
1
Extract columns names from any select query
Golang
This regex can capture any column name from a select query. Be the original name, like are named on table, renamed with a reserved word AS or even without explicit AS. Go on, and test with your query ;)
Submitted by
Jefferson Gouveia
-
6 years ago
1
Detect JSON entries
PCRE (PHP <7.3)
This Regexp here has probably been done a ton of times, but I kind of figured one out here, so I decided to post it anyways. It may or may not be a duplicate, but this also will ignore any strings that a JSON entry may have so that it knows not to detect something if a value contains text like "som...
Submitted by
Ghostyrun
-
6 years ago
1
GIT URL
ECMAScript (JavaScript)
no description available
Submitted by
UNKNW
-
6 years ago
1
c/c++ include
PCRE (PHP <7.3)
no description available
Submitted by
anonymous
-
6 years ago
1
find word near another word (10 words distance)
PCRE (PHP <7.3)
no description available
Submitted by
anonymous
-
6 years ago
1
Match Decimal allow single leading/tailing 0
ECMAScript (JavaScript)
Matches a decimal, but only allows for leading/tailing Zeros if they are the first digit to precede or follow the decimal point
Submitted by
Doom87er
-
6 years ago
1
...
278
279
280
281
282
...
902
Community Library Entry
1
Regular Expression
PCRE2 (PHP >=7.3)
/
^
(?:
(?:
10
\.
\d
{1,3}
\.
\d
{1,3}
\.
\d
{1,3}
|
172
\.
(?:
(?:
1
[
6
-
9
]
)
|
(?:
2
[
0
-
9
]
)
|
(?:
3
[
0
-
1
]
)
)
\.
\d
{1,3}
\.
\d
{1,3}
|
192
\.
168
\.
\d
{1,3}
\.
\d
{1,3}
|
127
\.
\d
{1,3}
\.
\d
{1,3}
\.
\d
{1,3}
)
(?:
:
\d
{1,5}
)?
)
$
/
gm
Open regex in editor
Description
Matches RFC1918 and Localhost ips.
Submitted by
nck
-
a year ago