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
ZIP Code
Open Workspace
PCRE2 (PHP)
Match
Created 2023-03-05 06:14
0
Regular Expression
/
\d
{5}
(?:
[
-
\s
]
\d
{4}
)?
/
gm
Description
ZIP Code validator
Submitted by
Donald Moore