PMTiles 是面向 Web 地图的无服务器矢量瓦片归档格式。单个文件包含所有瓦片,可通过 HTTP 范围请求访问。非常适合托管在 S3、CloudFlare R2、GitHub Pages 上,无需瓦片服务器。
OpenStreetMap data as of 5 October 2026 · 23 days ago
主要特点

关于 PMTiles 格式
PMTiles is an archive format in which a whole set of tiles sits in one file with an internal index. The browser does not download it as a whole: it requests the pieces it needs with HTTP range requests, which any static hosting can serve — S3, Cloudflare R2, GitHub Pages, plain Nginx.
Hence the main benefit: the map works without a tile server. There is no service to set up, watch over and pay for — the file simply sits next to the site. For a prototype, an internal dashboard or a project that has to outlive the shutdown of a third-party map service, that makes life noticeably easier.
Inside the archive are MVT vector tiles, that is geometry with attributes, and the appearance is set by a style on the client side. The export builds the pyramid up to zoom 12: beyond that encoding the tiles becomes too expensive, and if you asked for more, we honestly report the limitation and suggest MBTiles. For the same reason the exporter rejects very dense areas straight away rather than after a long wait: a short, clear refusal is better than a stuck job.
打开 PMTiles 文件的程序
以下程序可以打开、编辑和处理从 OSM2CDR 导出的 PMTiles(.pmtiles)文件:
格式规格
- 开放标准
- 仅 2D
- 无损(无质量损失)
- 存储要素属性
- 输出:1 个文件
- PMTiles single-file vector tile archive. Serverless deployment: drop on S3/CloudFront, range-request playback in MapLibre.
谁在使用 PMTiles 地图
如何导出 PMTiles
导出后如何打开
- PMTiles Viewer (pmtiles.io) — drag the file into the browser and see the contents right away: bounds, zooms, layers inside the tiles. The file is not uploaded anywhere in the process.
- MapLibre GL JS — add the pmtiles library, register the protocol and point at a source of the form pmtiles://https://your-domain/map.pmtiles, then describe the layers in style.json.
- Static hosting (S3, Cloudflare R2, GitHub Pages, Nginx) — put the file next to the site; make sure the server serves range requests (Accept-Ranges) and CORS headers if the domain is different.
- go-pmtiles — a command-line utility: pmtiles show displays the metadata and zooms, pmtiles convert turns the archive into MBTiles and back.
- QGIS — recent versions open PMTiles as a vector tile source through GDAL; convenient for a quick check that the data is in place.
PMTiles 格式的热门地图
导出 PMTiles 地图
从 OpenStreetMap 下载专业的 PMTiles 地图。任意区域,付款前即可看到价格。
常见问题
与其他格式比较
PMTiles 指南
相关格式
经常一起导出
Related Articles
PMTiles — Single-File Cloud Tile Archive for Serverless Maps (Protomaps)
PMTiles is a single-file Protomaps container for vector/raster tiles with HTTP range request reading: serverless map hos
comparisonVector MBTiles vs Raster MBTiles: Which One Your Project Needs
One SQLite container, two different maps: how MVT tiles differ from PNG tiles in size, styling, labels, Retina support a
guideDownload a city's tiles as one package: MBTiles, PMTiles and how to open them
How to download a city's tiles as one file and open it: MBTiles is an SQLite container for offline use and Android (OsmA