Regex To Match & Validate Iranian Postal Code

Category: Numbers

A regular expression to match and validate postal codes in Iran.

/\b(?!(\d)\1{3})[13-9]{4}[1346-9][013-9]{5}\b/

Matches:

  • 1193653471

Non-matches:

  • 0393653471

See Also:

Rate This Regex
Sending
User Review
0 (0 votes)

Expression Flags

Flags Description
i Ignore case sensitive.
g Allows global search.
m Allows multiline search.