Please enable JavaScript to use regex101
/
^
r
e
g
e
x
[
\
-
_
]
?
1
0
1
$
/
i
Reg
ular
Ex
pressions
101
Upgrade to Pro
Enterprise
Community Library
How to contribute
x
mac address validation
Open Workspace
PCRE2 (PHP)
Match
Created 2022-06-07 08:10
0
Regular Expression
/
(
(
(
[
0
-
9A
-
Fa
-
f
]
{2}
[
:-
]
){5}(
[
0
-
9A
-
Fa
-
f
]
{2}
)
)
|
(
(
[
0
-
9
]
{2,3}
[
:-
]
){5}(
[
0
-
9
]
{2,3}
)
)
)
/
gm
Description
mac address validation in hex or decimal form
Submitted by
planetwatch.io