Map tile bounds
The latitude and longitude bounds of a z/x/y tile or quadkey, with its , , and quadkey forms; detect mode shows both y conventions.
Go the other way: Map tile for a point (XYZ, TMS, quadkey) →
A published result changed on 2026-09-19: The geohash encoder, map tile for a point, tile bounds, H3 grid disk, and haversine distance are now stable, so their results no longer carry the EXPERIMENTAL_TOOL warning; the Web Mercator clamp and pentagon warnings moved to the first position. Each matches published worked examples (Wikipedia, the mercantile README, the Bing Maps Tile System, H3 C, and Rosetta Code) and agrees with a separately written library on 250 to 1,000 cases. No numbers changed. Changelog
Tile 12/1137/2551 spans latitude -40.4469471° to -40.3800284°.
- TMS tile
- Quadkey
- Center latitude
- Center longitude
- South
- West
Provenance
- Computed by
- indexing.tile.bounds 1.0.0, core 0.1.0
- Model
- Spherical Web Mercator tile grid; TMS y = 2^z − 1 − XYZ y
- Accuracy
- Exact
- Notes
- None
- Cites
- OpenStreetMap Wiki, Slippy map tilenames; Microsoft, Bing Maps Tile System
Something look off?
How we got thisFormula, worked example, sources, and proof
Model: Spherical Web Mercator tile grid; TMS y = 2^z − 1 − XYZ y
Show your work
Tiles across the map
2^12= 4,096West and east edges
lon = x / n × 360 − 180, for x and x+11,137 and 1,138 of 4,096= -80.068359° to -79.980469°Centre latitude
the latitude halfway down the tile in Web Mercator, not in degreesbetween -40.380028° and -40.446947°= -40.413496°
The same steps an agent gets from the MCP server with explain: true.
Accuracy: Exact
When to use this: Use this when a tile coordinate or a quadkey has to become geography: the latitude and longitude bounds of the tile, with its XYZ, TMS, and quadkey forms, which is what debugging a tile cache, a slippy map, or a tile-based pipeline needs. It is the quickest way to check that a tile pipeline is asking for the tile it means: compare the bounds it returns against the data that came back.
Limitations: The two y conventions are the usual trap: XYZ counts from the top and TMS from the bottom, so the same numbers name different tiles, and detect mode shows both rather than choosing. Web Mercator cuts off near the poles, and a tile's ground size depends on latitude. A quadkey encodes the zoom in its length, while z/x/y does not, so a tile coordinate without its zoom is meaningless. The bounds are the projection's, not the data's: a tile may be empty or clipped.
Worked example: 12/1137/2551 with detect. Source: add-spatial-indexing-and-raster scenario: tile y convention confusion.
You enter
- y convention
- detect
- Tile
- 12/1137/2551
You get
- XYZ tile
- 12/1137/2551
- TMS tile
- 12/1137/1544
- Quadkey
- 210223330223
- Center latitude
- -40.413496°
- Center longitude
- -80.0244141°
- South
- -40.4469471°
- West
- -80.0683594°
- North
- -40.3800284°
- East
- -79.9804688°
- Other convention
- As TMS, it is XYZ 12/1137/1544, latitude 40.3800 to 40.4469
Review: Not yet independently reviewed by a GIS professional.
Last verified: 2026-09-18, when a maintainer last confirmed this tool's sources at the issuer. See the sources ledger.
Status: version 1.0.0, core 0.1.0. See this tool in the verification report.
Changes
- 2026-09-19, result change: The geohash encoder, map tile for a point, tile bounds, H3 grid disk, and haversine distance are now stable, so their results no longer carry the EXPERIMENTAL_TOOL warning; the Web Mercator clamp and pentagon warnings moved to the first position. Each matches published worked examples (Wikipedia, the mercantile README, the Bing Maps Tile System, H3 C, and Rosetta Code) and agrees with a separately written library on 250 to 1,000 cases. No numbers changed. Changelog
Checked against: 26 golden test vectors (download the test vectors, each with its source and tolerance). See how results are checked and every source.
Sources
- Slippy map tilenames, OpenStreetMap Wiki, Current wiki page. Lon./lat. to tile numbers, tile numbers to lon./lat., resolution and scale.
- Bing Maps Tile System, Microsoft, Online documentation. Tile coordinates and quadkeys; ground resolution = cos(lat) × 2π × 6,378,137 / (256 × 2^level).
Terms
- TMS: Tile Map Service
- A web map tile numbering like XYZ, but with rows counted from the south edge. Source: Slippy map tilenames
- XYZ: XYZ web map tiles
- The common web map tile numbering, zoom/x/y, with rows counted from the north edge. Source: Slippy map tilenames
TMS — Tile Map Service
A web map tile numbering like XYZ, but with rows counted from the south edge.
Source: Slippy map tilenames
XYZ — XYZ web map tiles
The common web map tile numbering, zoom/x/y, with rows counted from the north edge.
Source: Slippy map tilenames
Learn the concept: Map tiles, zoom levels, and quadkeys explained