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...
0
text has numbers
ECMAScript (JavaScript)
text has numbers
Submitted by
vijay
-
a year ago
0
email matcher
PCRE2 (PHP >=7.3)
match some emails and extract their local part and domain
Submitted by
dang duomg 191
-
6 months ago
(Last modified 6 months ago)
1
...
900
901
902
Community Library Entry
1
Regular Expression
PCRE2 (PHP >=7.3)
/
^
(
(?#DDI)
(
\+
|
00
|
\+
00
)?
[
\s
\-\.
]
?
(
\(
?
[
5
]
{2}
\)
?
)?
)?
[
\s
\-\.
]
?
(
(?#DDD)
\(
?
0
?
(
[
1
-
9
]
{2}
)
\)
?
)
[
\s
\-\.
]
?
(
(?#Dígito)
9
)?
[
\s
\-\.
]
?
(
(?#Número)
(
(?#Primeira
Parte)
[
1
-
9
]
[
0
-
9
]
{3}
)
[
\s
\-\.
]
?
(
(?#Segunda
Parte)
[
0
-
9
]
{4}
)
)
\s
?
$
/
gm
Open regex in editor
Description
Regex validação número celular e fixo
Somente números nacionais
Com ou sem DDI 55
(com ou sem + e/ou 00)
DDD obrigatório
(com ou sem parênteses)
Com ou sem Dígito 9
Com ou sem espaços vazios, hífens ou pontos entre os capture groups
Substitui pelos capture groups mantendo somente os números no padrão abaixo
DDI+DDD+DÍGITO+NÚMERO = 552198887777
Submitted by
Danillo Dantas
-
2 years ago