maplibre-pmtiles-patterns

Generate and serve PMTiles for MapLibre GL JS from static hosting.

Updated Feb 5, 2026
One-click install
npx skills add https://github.com/JNZader/consorcio-canalero --skill maplibre-pmtiles-patterns
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: maplibre-pmtiles-patterns
Source: https://github.com/JNZader/consorcio-canalero/tree/main/.codex/skills/maplibre-pmtiles-patterns
Command: npx skills add https://github.com/JNZader/consorcio-canalero --skill maplibre-pmtiles-patterns

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

PMTiles enable hosting vector and raster map tiles as single-file archives on static storage, removing the need for a dedicated tile server and enabling efficient HTTP range requests for fast map rendering.

Core Features & Use Cases

  • Static hosting of PMTiles files (S3/R2/GitHub Pages) with proper CORS and long cache headers.
  • Generate PMTiles from MBTiles or source data using Planetiler, tippecanoe, or GDAL, then serve them directly.
  • Integrate with MapLibre GL JS via the PMTiles protocol to render multiple layers from a single file.

Quick Start

Upload your .pmtiles file to a static host and configure MapLibre GL JS to load it via the pmtiles protocol.

Frequently Asked Questions about maplibre-pmtiles-patterns

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I serve vector tiles for MapLibre GL JS without a tile server?

You can serve vector tiles for MapLibre GL JS without a tile server by using PMTiles archives on static hosting. This enables efficient HTTP range requests for fast map rendering without requiring a dedicated backend.

Can I host PMTiles on static storage like S3 or GitHub Pages for MapLibre?

Yes, you can host PMTiles on static storage like S3, Cloudflare R2, or GitHub Pages for MapLibre. You need to configure proper CORS and long cache headers to ensure the client can fetch tiles efficiently.

How do I generate PMTiles from source data using tippecanoe or Planetiler?

To generate PMTiles from source data, you can use tools like Planetiler, tippecanoe, or GDAL to convert your data or MBTiles files into single-file PMTiles archives ready for static hosting.

How do I integrate the PMTiles protocol into a MapLibre style?

To integrate the PMTiles protocol into a MapLibre style, you wire the protocol into your MapLibre GL JS client. This allows you to render multiple vector and raster layers from a single PMTiles file.

What is the best way to host map tiles without a dedicated server?

The best way to host map tiles without a dedicated server is using PMTiles archives on static storage. This removes the need for a tile server by enabling efficient HTTP range requests directly from static hosts.

Does PMTiles work with both vector and raster layers in MapLibre?

Yes, PMTiles works with both vector and raster layers in MapLibre. The workflow includes hosting the archive and wiring the pmtiles protocol in your MapLibre style to render multiple layer types from a single file.