us zip code validation
There are times when you may want to use the 9 digit zip code validation for US. The 9 digit zip code is usually in format like this #####-####. For a 9 digit US zip code validation use below regular Expression. ^([0-9]{5}-[0-9]{4})$.
For US Zip code validation Use below regular Expression. ^([0-9]{5})$. For Canada Postal code validation Use below regular Expression to validate the zip/postal code in your form. ^[ABCEGHJKLMNPRSTVXYabceghjklmnprstvxy]{1}\d{1}[A-Za-z]{1} *\d{1}[A-Za-z]{1}\d{1}$.