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 4,520 community submitted regex patterns...
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Test mail
PCRE2 (PHP >=7.3)
Email test
Submitted by
anonymous
-
a year ago
2022-09-23 14:23
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Prefixed numerics
Python
Search regex for prefixed numerics (kB, Mb. ms. kHz etc.)
Submitted by
delameter
-
a year ago
2022-09-23 16:47
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Invalid HTML syntax regex
PCRE2 (PHP >=7.3)
A bare demo of detecting syntactically invalid HTML, created for jridgewell/proposal-regexp-atomic-and-possessive#1. It's a proposal for the + quantifier modifier for ECMAScript regular expressions. Currently only properly detects invalid ending tags, and is only about having the correct syntax.
Submitted by
Keyacom
-
a year ago
2022-09-23 20:27
(Last modified a year ago)
2022-09-23 21:29
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Get project name from git url
Golang
Used by Zarf to obtain the name of a repository when given a git URL.
Submitted by
Jonathan Perry
-
a year ago
2022-09-26 13:58
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Zarf docker registry domain matcher (v2)
PCRE2 (PHP >=7.3)
Used by Zarf to swap the registry domain/port part an image url without needed the docker libraries. usage in go: // SwapHost Perform base url replacement and adds a sha1sum of the original url to the end of the src func SwapHost(src string, targetHost string) (string, error) { targetImage, err ...
Submitted by
Jonathan Perry
-
a year ago
2022-09-26 14:03
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Celular Brasil
PCRE2 (PHP >=7.3)
Validar celular do Brasil
Submitted by
Paulo Neves
-
a year ago
2022-09-26 15:12
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Sizes
Python
Getting sizes, formatted as in x or x. It supports up to 3 digits, with an additional, optional, decimal digit. The decimal point could be a comma, a point or even an apostrophe ( ' ).
Submitted by
Hermes
-
a year ago
2022-09-28 07:56
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Sélectionner le contenu entre parenthèses
PCRE2 (PHP >=7.3)
Sélectionner le contenu entre parenthèses (parenthèses comprises)
Submitted by
scalpa
-
a year ago
2022-09-28 09:25
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
match a substring starting from a word and ending at a word
PCRE2 (PHP >=7.3)
match a substring starting from a word and ending at a word
Submitted by
anonymous
-
a year ago
2022-09-28 20:11
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Url breakdown
PCRE2 (PHP >=7.3)
Check validity of url and break it down into logical parts.
Submitted by
jokle
-
a year ago
2022-09-29 08:57
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Get X range of words from a string
PCRE2 (PHP >=7.3)
Get words in a certain range from a varied string
Submitted by
anonymous
-
a year ago
2022-09-29 14:38
(Last modified a year ago)
2022-10-01 14:43
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
hidrologia
PCRE2 (PHP >=7.3)
qualidade
Submitted by
anonymous
-
a year ago
2022-09-30 14:59
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
InputInteger
PCRE2 (PHP >=7.3)
InputInteger
Submitted by
anonymous
-
a year ago
2022-09-30 16:30
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Extract countries names in a spaceless string
PCRE2 (PHP >=7.3)
works with strings such as: U.K.TanzaniaU.S.A., UkraineFrance, GermanyU.S.A. Issues: Doesn't work with repeating acronyms, e.g.: U.K.U.S.A.; possible fix: (?:[A-Z]\.){1,3}|A-Z+ Works only with country's acronyms that have the same number of dots as the number of capital letters
Submitted by
whatserface
-
a year ago
2022-09-30 16:42
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Match and capture (go) one or more times
PCRE2 (PHP >=7.3)
Match and capture (go) one or more times
Submitted by
anonymous
-
a year ago
2022-10-01 15:28
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Split URL
Python
source = "https://regex101.com/r/Y5b7zZ/3" result = ("https", "regex101.com", "/r/Y5b7zZ/3") `
Submitted by
saparapat
-
a year ago
2022-10-01 18:37
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
bkengine多行宏正则解析
Python
用于解析bkengine的宏代码 如果代码的开头是形如// 这种注释,你需要先通过编程代码手动判断此行的开头是否为注释,如果是,则不处理后面的diam 如果注释在宏代码的后面 此正则不会处理在尾部的单行注释 注:此宏仅支持当行宏匹配(多行宏匹配可能会出现小问题)
Submitted by
小沙盒工作室
-
a year ago
2022-10-02 02:31
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
bkengine多行宏解析器
Python
简体中文: 用于解析bkengine的宏代码 如果代码的开头是形如// 这种注释,你需要先通过编程代码手动判断此行的开头是否为注释,如果是,则不处理后面的diam 如果注释在宏代码的后面 此正则不会处理在尾部的单行注释 注:此宏仅支持当行宏匹配(多行宏匹配可能会出现小问题)...
Submitted by
小沙盒工作室
-
a year ago
2022-10-02 04:34
(Last modified a year ago)
2022-10-02 04:35
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
bkengine 多行宏词法分析 添加了分组参数
Python
bkengine 多行宏词法分析 添加了分组参数
Submitted by
小沙盒工作室
-
a year ago
2022-10-02 13:21
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
matches 4 or 6 or 8 digit which might be otp
PCRE2 (PHP >=7.3)
test
Submitted by
test
-
a year ago
2022-10-02 15:03
1
...
153
154
155
156
157
158
159
...
226
test
0
0 upvotes, 0 downvotes (score 0%) (You must be signed in to vote)
Regular Expression
Python
r"
(?<=
\n
)
\w
{10}
\w
{0,5}
(?=
\w
{0,9}
)
\s
{0,18}
"
gm
Open regex in editor
Description
Loading markdown...
Submitted by
anonymous
-
4 years ago
2019-09-28 16:47