Postal code · code postal

Morocco postal codes

Morocco postal codes have the format ##### (5 digits), for example 53000. zipcodestack has 307 postal codes for Morocco in 12 regions.

Format
#####
Example
53000
Codes in our database
307
Local name
code postal

Morocco postal code format

Pattern##### (# digit, @ letter)
Examples53000, 10000, 20050, 16052
Regex^(?:\d{5})$

Format and regex from Google's address metadata (libaddressinput). The regex checks the shape of a code, not whether it exists.

Postal Codes by region

RegionRangeCodes
Béni Mellal-Khénifra22000 – 54524151
Casablanca-Settat13000 – 29672117
Dakhla-Oued Ed-Dahab73000 – 740022
Drâa-Tafilalet45000 – 52623125
Fès-Meknès30023 – 53124222
Guelmim-Oued Noun81000 – 8202331
Laâyoune-Sakia El Hamra70022 – 720007
Marrakesh-Safi40023 – 46322183
Oriental60005 – 6582389
Rabat-Salé-Kénitra11022 – 1632499
Souss-Massa80022 – 87702195
Tanger-Tetouan-Al Hoceima32000 – 94152104

Postal Codes of the largest cities

Neighbouring countries

Morocco postal codes: FAQ

What is the postal code format in Morocco?

Morocco postal codes follow the pattern ##### (# = digit, @ = letter), i.e. 5 digits. Examples: 53000, 10000, 20050, 16052.

What regex validates Morocco postal codes?

^(?:\d{5})$ matches the official format (from Google's address metadata). It checks the shape only; whether a code exists needs a lookup in a postal code database such as the zipcodestack API.

What are postal codes called in Morocco?

In Morocco the postal code is called code postal.

How many postal codes are there in Morocco?

The zipcodestack database contains 307 postal codes for Morocco, each with place name, region and coordinates.

Postal code API

Look up Morocco postal codes by API

zipcodestack looks up, validates and searches postal codes in 149 countries: city, state, coordinates, distances and radius search, as JSON.

/v1/search documentation International postal code API All documentation

300 free requests every month. No credit card required.

GET https://api.zipcodestack.com/v1/search?codes=53000&country=ma

{
  "results": {
    "53000": [{
      "postal_code": "53000",
      "country_code": "MA",
      "city": "…",
      "state": "…",
      "latitude": …,
      "longitude": …
    }]
  }
}

Free postal code tools

Start using our ZIP Code API for free today!

Get 300 requests / month for free