Mexico Postal Code Validator

Validate Mexican 5-digit códigos postales by state prefix

Ad placeholder (leaderboard)

A Mexican código postal (CP) is the 5-digit code SEPOMEX (Servicio Postal Mexicano) assigns to every delivery zone. The numbering plan is geographic: each state owns one or more blocks of leading digits, so the first one or two digits of any valid CP tell you which state it belongs to. This free validator checks the format and resolves the state, which is handy for e-commerce checkout validation and cleaning Mexican address data.

How it works

  1. Strip non-digits and confirm the result is exactly 5 digits.
  2. Confirm the numeric value is within the assigned range (01000–99998).
  3. Read the leading digits and match them against the SEPOMEX state blocks. Mexico City uses the 0xxxx range; states like Jalisco (44–49), Nuevo León (64–67) and Yucatán (97) own contiguous prefix bands.

The tool returns whether the code is well-formed and, when it is, the state the prefix maps to.

Example

For 06000, the format is valid (5 digits, in range) and the leading 0 resolves to Ciudad de México. For 44100, the prefix 44 resolves to Jalisco (Guadalajara). A 4-digit entry like 6000 is rejected because Mexican codes always carry their leading zero.

Notes

A passing result means the CP is structurally valid and lands in a real state block — not that the specific code is an assigned delivery zone. For authoritative per-CP data (colonia, municipio), query the official SEPOMEX dataset. All processing here is local to your browser.

Ad placeholder (rectangle)