Country

Geocode Canadian addresses offline

One file for all provinces and territories, read locally; answers carry the Canadian postal code. No server, no API key, and the addresses you geocode never leave your machine.

Get started

The file for Canada is 183 MB and holds 16.94 million addresses from the Statistics Canada National Address Register, Adresses Québec and the Government of Yukon (via Overture Maps). Download it once, checked against the signed release; every query after that runs on your machine, with no API key and no rate limit.

terminalpip
$ pip install gridpin-mcp   # includes the engine
$ gridpin-fetch ca         # Canada, 183 MB, verified download
geocode.pyPython
import gridpin
from gridpin_mcp import sheets

g = gridpin.Geocoder(str(sheets.download("ca")))  # no-op once downloaded

g.geocode("1600 Barrington St, Halifax, NS", 1)
# -> house, Barrington ST 1600, Halifax, B3J 1Z6
g.geocode("1001 Rue Sherbrooke Ouest, Montréal, QC H3A 1G5", 1)
# -> house, rue Sherbrooke O 1001, Montréal, H3A 1G5
g.geocode("10405 Jasper Ave NW, Edmonton, AB", 1)
# -> house, Jasper AVE NW 10405, Edmonton, T5J 3N4
g.geocode("Toronto (290 Bremner Blvd) ON", 1)
# -> interp, Bremner BLVD 290, Toronto

English and French street forms both work (Rue Sherbrooke Ouest, Blvd Manseau), and the place may come first (OTTAWA, ON - 100 Queen St). The postal code is read with or without the space and returned in the answer; the Edmonton and Calgary quadrants (NW, SW) are found when left out. interp means the number was placed between neighbouring houses of the same street.

How often it finds the right house, compared with Nominatim and Photon on independent truth: benchmark. Try it without installing: the live demo (pick Canada in the list), or the Colab notebook (set COUNTRY = "ca").