GDAL2Tiles Utility

Manual page for

NOTE: This manual page is available at

Usage tips and FAQ

Creating one KMZ file from generated structure

You need to zip (by zip, pkzip, WinZip, ...) content of the generated directory the way, that doc.kml is directly available in the root of zip. Then rename .zip to .kmz and whole pyramid structure is available as one huge file. Google Earth should open such file without troubles.

If you need to publish the map online, it is better to upload generated structure directly as it was generated, then tiles are requested separately and users don't need to wait for dowload of the whole map. One huge KMZ is nice for CD-ROM distribution for example.

Why KML generator needs raster files with EPSG:4326 projection?

Google Earth expect raster tiles in this projection. You can use gdalwarp utility from GDAL (or FWTools) to warp your existing rasters into EPSG:4326. If you are sure, that your raster internally use correct coordinates, but does not generate KML files, then use -forcekml parameter.

File with name doc.kml is generated always. It is for local computer usage and for KMZ. If you would like to generate Google Earth KML Superoverlay for distributing online, then specify -publishurl parameter and another kml file (with the file name same like output_dir) is generated. This KML file you can send by email or publicly linked, it should contain correct url for published tiles.

Can I use tiles as overlay on Google Maps?

Not yet. For this functionality TMS global-* profiles need to be implemented. It is on the TODO list (any support is welcome ;-)). If you would like to generate overlays from vector data, then use Mapnik Project

Project web site

GDAL2Tiles - Raster Maps Tile Publishing and KML Generation at

More info

This utility was created as a project GDAL2Tiles in Google Summer of Code 2007.

Last modified 4 months ago Last modified on Jun 1, 2023, 8:26:19 AM
Note: See TracWiki for help on using the wiki.