Maps API — Vector Tile Reference
Complete reference for Township Canada vector tile layers. Available grid layers by province, data layers, tile URL patterns, styling guide, and recommended zoom ranges.
The Maps API serves Canadian survey grids and geographic data as Mapbox Vector Tiles (MVT). This reference covers every available tileset, their source layers, tile URL patterns, recommended zoom ranges, and styling values.
For step-by-step integration examples, see the library-specific guides linked at the bottom of this page.
Tile URL pattern
https://maps.townshipcanada.com/{province}/{layer}/{z}/{x}/{y}.mvt?api_key=YOUR_API_KEY
Supported provinces: ab, sk, mb, bc, on
Example — Alberta township boundaries:
https://maps.townshipcanada.com/ab/twp/{z}/{x}/{y}.mvt?api_key=YOUR_API_KEY
Example — Saskatchewan sections:
https://maps.townshipcanada.com/sk/sec/{z}/{x}/{y}.mvt?api_key=YOUR_API_KEY
Data layers use the same base URL without a province prefix:
https://maps.townshipcanada.com/{data_layer}/{z}/{x}/{y}.mvt?api_key=YOUR_API_KEY
Example — oil and gas field boundaries:
https://maps.townshipcanada.com/oil_gas_fields/{z}/{x}/{y}.mvt?api_key=YOUR_API_KEY
Grid layers by province
DLS grid — Alberta, Saskatchewan, Manitoba, BC Peace River
The Dominion Land Survey (DLS) system covers Alberta, Saskatchewan, Manitoba, and the Peace River region of British Columbia. Available for provinces: ab, sk, mb, bc.
Replace {prov} with the province code in the source-layer column.
| URL layer | source-layer | text-field | Source zoom | Layer zoom |
|---|---|---|---|---|
twp | {prov}_twp | — | 0–14 | 6–12 |
twp-label | {prov}_twp_label | {descriptor} | 0–14 | 10–12 |
sec | {prov}_sec | — | 9–14 | 12–14 |
sec-label | {prov}_sec_label | {section} | 9–14 | 12–14 |
qtr | {prov}_qtr | — | 9–14 | 12–14 |
qtr-label | {prov}_qtr_label | {descriptor} | 9–14 | 12–14 |
lsd | {prov}_lsd | — | 9–14 | 14–20 |
lsd-label | {prov}_lsd_label | {lsd} | 9–14 | 14–20 |
Example — Alberta township boundaries and labels:
map.addSource("ab_twp", {
type: "vector",
tiles: ["https://maps.townshipcanada.com/ab/twp/{z}/{x}/{y}.mvt?api_key=YOUR_API_KEY"],
minzoom: 0,
maxzoom: 14
});
map.addLayer({
id: "ab_twp",
type: "line",
source: "ab_twp",
"source-layer": "ab_twp",
minzoom: 6,
maxzoom: 12,
paint: { "line-color": "#2d5a47", "line-width": 1.5 }
});
map.addSource("ab_twp_label", {
type: "vector",
tiles: ["https://maps.townshipcanada.com/ab/twp-label/{z}/{x}/{y}.mvt?api_key=YOUR_API_KEY"],
minzoom: 0,
maxzoom: 14
});
map.addLayer({
id: "ab_twp_label",
type: "symbol",
source: "ab_twp_label",
"source-layer": "ab_twp_label",
minzoom: 10,
maxzoom: 12,
layout: { "text-field": "{descriptor}", "text-size": 14 },
paint: { "text-color": "#333", "text-halo-color": "#fff", "text-halo-width": 2 }
});
River Lots — Manitoba
Manitoba includes river lot boundaries in addition to the DLS grid. Available for province: mb.
| URL layer | source-layer | text-field | Source zoom | Layer zoom |
|---|---|---|---|---|
river-lots | mb_river_lots | — | 0–14 | 12–20 |
river-lots-label | mb_river_lots_label | {descriptor} | 0–14 | 12–20 |
NTS grid — British Columbia
Most of British Columbia uses the National Topographic System (NTS). NTS grid tiles cover four levels of the map sheet hierarchy. Available for province: bc.
| URL layer | source-layer | text-field | Source zoom | Layer zoom |
|---|---|---|---|---|
series | bc_series | — | 0–14 | 0–10 |
series-label | bc_series_label | {descriptor} | 0–14 | 7–10 |
block | bc_block | — | 9–14 | 10–13 |
block-label | bc_block_label | {descriptor} | 9–14 | 10–13 |
unit | bc_unit | — | 9–14 | 13–14 |
unit-label | bc_unit_label | {descriptor} | 9–14 | 13–14 |
qtr-unit | bc_qtr_unit | — | 9–14 | 14–20 |
qtr-unit-label | bc_qtr_unit_label | {descriptor} | 9–14 | 14–20 |
Geographic Townships — Ontario
Ontario uses geographic townships with concessions and lots rather than DLS or NTS grids. Available for province: on.
| URL layer | source-layer | text-field | Source zoom | Layer zoom |
|---|---|---|---|---|
twp | on_twp | — | 0–14 | 6–12 |
twp-label | on_twp_label | {descriptor} | 0–14 | 6–12 |
con | on_con | — | 0–14 | 12–14 |
con-label | on_con_label | {descriptor} | 0–14 | 12–14 |
lot | on_lot | — | 0–14 | 14–20 |
lot-label | on_lot_label | {descriptor} | 0–14 | 14–20 |
Data layers
Data layers cover geographic and industrial features across Canada. All data tilesets use source zoom 0–12 — they do not contain data above zoom 12, so set your source maxzoom accordingly.
The source-layer name matches the tileset name. The label source-layer name matches the label tileset name.
| Tileset | Label tileset | text-field | Placement | Description |
|---|---|---|---|---|
oil_gas_fields | oil_gas_fields_label | {name} | point | Petroleum field boundaries |
municipal_boundaries | municipal_boundaries_label | {name} | point | Municipal and county borders |
parks_and_protected_areas | parks_and_protected_areas_label | {name} | point | National and provincial parks |
water_bodies | water_bodies_label | {name} | point | Lakes and reservoirs |
watercourses | (same tileset) | {name} | line | Rivers and streams |
railways | (same tileset) | {name} | line | Railway lines |
roads | (same tileset) | {name}m | line | Road network |
elevation | (same tileset) | {elevation}m | line | Contour lines |
Example — oil and gas field boundaries with labels:
map.addSource("oil_gas_fields", {
type: "vector",
tiles: ["https://maps.townshipcanada.com/oil_gas_fields/{z}/{x}/{y}.mvt?api_key=YOUR_API_KEY"],
minzoom: 0,
maxzoom: 12
});
map.addLayer({
id: "oil_gas_fields",
type: "line",
source: "oil_gas_fields",
"source-layer": "oil_gas_fields",
paint: { "line-color": "#b45309", "line-width": 1 }
});
map.addSource("oil_gas_fields_label", {
type: "vector",
tiles: [
"https://maps.townshipcanada.com/oil_gas_fields_label/{z}/{x}/{y}.mvt?api_key=YOUR_API_KEY"
],
minzoom: 0,
maxzoom: 12
});
map.addLayer({
id: "oil_gas_fields_label",
type: "symbol",
source: "oil_gas_fields_label",
"source-layer": "oil_gas_fields_label",
layout: { "text-field": "{name}", "text-size": 12, "symbol-placement": "point" },
paint: { "text-color": "#b45309", "text-halo-color": "#fff", "text-halo-width": 1.5 }
});
Styling guide
These color values are used throughout the integration examples and match the Township Canada visual style.
Grid boundaries
| Grid level | Color | Line width |
|---|---|---|
| Township boundaries | #2d5a47 (forest green) | 1.5 |
| Section boundaries | #4a7c59 | 1.0 |
| Quarter section boundaries | #6b9e7a | 0.75 |
| LSD boundaries | #6b9e7a | 0.5 |
Data layers
| Layer | Color | Notes |
|---|---|---|
| Oil & gas fields | #b45309 (amber) | Line or fill |
| Municipal boundaries | #6366f1 (indigo) | Dashed line — line-dasharray: [4, 2] |
| Parks and protected areas | #16a34a (green) | Fill with low opacity |
| Water bodies | #2563eb (blue) | Fill |
| Railways | #71717a (gray) | Line |
| Roads | #94a3b8 (slate) | Line |
Label text
paint: {
'text-color': '#1a1a1a',
'text-halo-color': '#ffffff',
'text-halo-width': 2
}
Performance tips
Set source maxzoom to 14 for grid tiles. The tiles are generated at zoom 14 and over-zoom cleanly to higher zoom levels. Loading tiles beyond source zoom 14 wastes requests without adding detail.
Set source maxzoom to 12 for data layers. Data layers contain no additional detail above zoom 12. Setting a higher source maxzoom generates unnecessary tile requests.
// Grid tiles — cap source at 14
map.addSource("ab_twp", {
type: "vector",
tiles: ["https://maps.townshipcanada.com/ab/twp/{z}/{x}/{y}.mvt?api_key=KEY"],
minzoom: 0,
maxzoom: 14 // Not 20
});
// Data layers — cap source at 12
map.addSource("oil_gas_fields", {
type: "vector",
tiles: ["https://maps.townshipcanada.com/oil_gas_fields/{z}/{x}/{y}.mvt?api_key=KEY"],
minzoom: 0,
maxzoom: 12 // Not 14 or 20
});
Use layer minzoom/maxzoom to control visibility. Add all sources once, then use layer-level zoom constraints to show each grid level at the right scale. This avoids adding and removing sources dynamically as the user zooms.
// Townships visible at zoom 6–12
map.addLayer({ id: 'ab_twp', ..., minzoom: 6, maxzoom: 12 });
// Sections visible at zoom 12–14
map.addLayer({ id: 'ab_sec', ..., minzoom: 12, maxzoom: 14 });
// LSDs visible at zoom 14+
map.addLayer({ id: 'ab_lsd', ..., minzoom: 14, maxzoom: 20 });
Enable tile caching in your mapping library. Mapbox GL JS, MapLibre GL JS, and OpenLayers all cache vector tiles in memory by default. Avoid clearing the map and re-initializing sources on every state change — update layer visibility instead.
Load only the provinces you need. If your application covers only Alberta and Saskatchewan, add tile sources only for ab and sk. Each province has its own tile URL, so you only fetch and render the data you need.
Quick reference
| URL segment | Values |
|---|---|
{province} | ab, sk, mb, bc, on |
| DLS grid layers | twp, twp-label, sec, sec-label, qtr, qtr-label, lsd, lsd-label |
| NTS grid layers | series, series-label, block, block-label, unit, unit-label, qtr-unit, qtr-unit-label |
| MB river lots | river-lots, river-lots-label |
| Ontario layers | twp, twp-label, con, con-label, lot, lot-label |
| Tile format | MVT (Mapbox Vector Tiles) |
| Grid source maxzoom | 14 |
| Data source maxzoom | 12 |
Related guides
- API Integration Guide — API endpoints, pricing, and key management
- Mapbox GL JS Integration — Full working example with DLS grids, search, and data layers
- MapLibre GL JS Integration — Open-source alternative to Mapbox GL JS
- OpenLayers Integration — Vector tile rendering with OpenLayers
- Leaflet Integration — Adding survey grids to Leaflet maps
Related Guides
Legal Land Description API Integration Guide
Integrate legal land description APIs into your applications. Convert LLDs to coordinates, add autocomplete search, process batch records, and display DLS/NTS grid maps. REST API with JSON responses.
Managing API Keys for Development, Staging, and Production
Create and manage multiple Township Canada API keys for different environments. Naming conventions, key rotation, environment variables, and CI/CD setup.
Building Autocomplete Search with the Township Canada API
Build a search-as-you-type component for legal land descriptions using the Township Canada Autocomplete API. Includes debouncing, proximity biasing, and examples in vanilla JS and React.