#pmtiles #map-tile #archive #download #xyz #png #tileset #tile-map

app tile-download-tool

A tool to download XYZ map tiles to a PMTiles archive

4 releases

Uses new Rust 2024

0.2.1 Sep 22, 2025
0.2.0 Sep 9, 2025
0.1.1 Sep 5, 2025
0.1.0 Sep 4, 2025

#187 in Compression

Download history 231/week @ 2025-09-02 115/week @ 2025-09-09 93/week @ 2025-09-16 50/week @ 2025-09-23 13/week @ 2025-09-30 1/week @ 2025-10-07

203 downloads per month

MIT license

42KB
985 lines

tile-download-tool

English | 日本語

Crates.io Version

Download XYZ tiles in to a PMTiles archive

Usage

$ tile-download-tool https://example.com/tileset/{z}/{x}/{y}.png example_tileset.pmtiles

Installation

Compiled binaries are available on the Releases page. Download the binary for your architecture and run it in a terminal.

If you have a Rust environment installed, you may cargo install tile-download-tool as well.

Options

  • --minimum-zoom, -Z, --maximum-zoom, -z - limit the zoom levels to download
  • --tile-list [file] - a list of tiles to download
  • --tile-list-format [format] - the format the tile-list file is in
    • z x y will be used as the zoom, x, and y values respectively.
    • --tile-list-format "z x y" - lines of z x y (for example, 0 0 0)
    • --tile-list-format "z/x/y" - lines of z/x/y
    • --tile-list-format "z/y/x"
    • --tile-list-format "z,x,y"
    • ,etc. A regex will be compiled based on the format and used for matching.
  • --bbox, -b - A bounding box in the format "min_x,min_y,max_x,max_y" to filter the downloaded tiles
  • --concurrency - limit the download concurrency (defaults to 10)
  • --append, -a - append to an existing PMTiles file; preloads existing tiles and downloads only the missing ones. Note that this only works when the PMTiles file in question has been downloaded in order -- tile-download-tool does this, so any archive partially downloaded by this tool will be able to be appended to.
  • --force, -f - overwrite the output file if it already exists

See all options with --help

Dependencies

~20–40MB
~489K SLoC