Tiles à la Google Maps

Coordinates, Tile Bounds and Projection

Learn how zoomable maps works, what coordinate systems are, and how to convert between them.


TIP: Click on the map to get details for a tile!

How does a zoomable map work?

People have been using coordinate systems and map projections to transform the shape of Earth into usable flat maps for centuries.

A map of the entire world is too big to be directly displayed on a computer. Therefore, there is a clever mechanism for quick browsing and zooming on maps: the map tiles.

The world is divided into small squares, each with a fixed geographic area and scale. This clever trick allows you to browse just a small part of the planet without loading the whole map - and you still get an illusion of exploring a single huge document.

Spherical Mercator

Pioneered by Google, now standardized.

Google Maps was one of the first systems for displaying dynamic maps on the web. They chose a Spherical Mercator projection because it preserves shape and angles. The entire world looks like a square, making it easy to work with on a computer.

Almost every open source (e.g., OpenStreetMap) and commercial Maps API provider (e.g., MapTiler Cloud) are now using this projection and tiling profile. The tiles are therefore compatible with each other.

spherical mercator graph

Convert coordinates for using global map tiles

Map of Earth

Degrees Geodetic coordinates WGS84 (EPSG:4326)

Longitude and latitude coordinates are used by GPS devices for defining position on Earth using World Geodetic System defined in 1984 (WGS84).

HINT: WGS84 geodetic datum specifies lon/lat (lambda/phi) coordinates on defined ellipsoid shape with defined origin ([0,0] on a prime meridian).

World displayed using mercator projection

Meters Projected coordinates Spherical Mercator (EPSG:3857)

Global projected coordinates in meters for the entire planet. Used for raster tile generation in GIS and WM(T)S services.

HINT: Simpler spherical calculations are used instead of ellipsoidal. Mercator map projection deforms size (Greenland vs. Africa) and never shows poles.

Pyramid with explanation of resolution and zoom levels

Pixels Screen coordinates XY pixels at zoom

Zoom-specific pixel coordinates for each level of the pyramid. Top level (zoom=0) has usually 256x256 pixels, next level 512x512, etc.

Devices calculate pixel coordinates at defined zoom level and determine visible viewport for an area which should be loaded from servers.

map tiles graph

Tiles Tile coordinates Tile Map Service (ZXY)

Coordinates of a tile in the pyramid. There is one tile on the top of the pyramid, then 4 tiles, 16 tiles, etc. All raster tiles have the same size, usually 256x256 or 512x512 pixels. Vector tiles work a bit differently.

Only the relevant tiles are loaded and displayed for the area of interest/viewport.


MapTiler Maps API as a platform for web and mobile devs

MapTiler makes it easy to build maps for your websites and mobile apps. Choose from street & satellite maps of the entire world or create a custom map design.

The platform is suitable for developers ranging from newbies to experts.

Use maps via API     Learn more

Resolution and scales

List of resolutions and scales of a pyramid in Spherical Mercator projection

Zoom level Resolution (meters / pixel) Map Scale (at 96 dpi) Width and Height of map (pixels)
0 156,543.0339 1 : 591,658,710.90 512
1 78,271.51696 1 : 295,829,355.45 1,024
2 39,135.75848 1 : 147,914,677.73 2,048
3 19,567.87924 1 : 73,957,338.86 4,096
4 9,783.939620 1 : 36,978,669.43 8,192
5 4,891.969810 1 : 18,489,334.72 16,384
6 2,445.984905 1 : 9,244,667.36 32,768
7 1,222.992452 1 : 4,622,333.68 65,536
8 611.4962263 1 : 2,311,166.84 131,072
9 305.7481131 1 : 1,155,583.42 262,144
10 152.8740566 1 : 577,791.71 524,288
11 76.43702829 1 : 288,895.85 1,048,576
12 38.21851414 1 : 144,447.93 2,097,152
13 19.10925707 1 : 72,223.96 4,194,304
14 9.554728536 1 : 36,111.98 8,388,608
15 4.777314268 1 : 18,055.99 16,777,216
16 2.388657133 1 : 9,028.00 33,554,432
17 1.194328566 1 : 4,514.00 67,108,864
18 0.597164263 1 : 2,257.00 134,217,728
19 0.298582142 1 : 1,128.50 268,435,456
20 0.149291071 1 : 564.25 536,870,912
21 0.074645535 1 : 282.12 1,073,741,824
22 0.037322768 1 : 141.06 2,147,483,648
23 0.018661384 1 : 70.53 4,294,967,296

EPSG.io - Coordinate systems worldwide

Open Source project for the visualization of all coordinate systems in the world. Convert coordinated online, get coordinates from a map in different projections, browse the coordinate database.

Look at the Spherical Mercator in EPSG.io.
Batch transform coordinates via API.

Source code for utilities for conversion between tiles and coordinates

Usage: python globalmaptiles.py [zoom] [lat] [lon]

Other people ported this code to additional programming languages

JavaScript| CSharp| PHP| Java| Ruby

Try MapTiler Cloud now!

Free account for personal use and evaluation.
API documentation for developers.

Start for free