Please enable JavaScript to use regex101
/
^
r
e
g
e
x
[
\
-
_
]
?
1
0
1
$
/
i
Reg
ular
Ex
pressions
101
Upgrade to Pro
Enterprise
Regular Expression
/
(?:(?:25[0-5]|(?:2[0-4]|1[0-9]|[1-9]|)[0-9])(?:\.(?!$)|$)){4}
/
gm
Input 1
New
validates: 0.0.0.0:0 255.0.0.0 192.168.1.0:8080 does not validate: 192.168.0.0/24 192.168..1 192.168.1
Substitution
validates: 0.0.0.0:0 255.0.0.0 192.168.1.0:8080 does not validate: 192.168.0.0/24 192.168..1 192.168.1