mapbox-vector-tile
Mapbox Vector Tile encoding and decoding.
What it is and what it does
Mapbox Vector Tile is a library for encoding geographic features into and decoding them from the MVT binary format, which is a widely used standard for transmitting vector map data efficiently over the web. It works with geometries in WKT (Well-Known Text), WKB (Well-Known Binary), or shapely objects, and handles the coordinate scaling and transformation needed to fit geometries into the tile's 4096-unit extent.
The library sits between your geographic data and the tile format, managing the protocol buffer serialization and layer organization. It supports coordinate system conversions when you provide tile bounds, allowing you to work with data in one projection and transform it into tile-relative coordinates. The core dependencies are protobuf for binary encoding, shapely for geometry handling, and pyclipper for polygon clipping operations.
Use it for:
- Encode geographic features from a database or GIS system into MVT format for serving to web map clients.
- Decode MVT tiles received from a tile server to extract and analyze feature properties and geometries.
- Transform geometries from different projections into tile coordinates for encoding.
- Build a tile generation pipeline that processes vector data and outputs MVT files for map rendering.
- Integrate with web mapping frameworks that consume MVT tiles as a data source.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Encodes and decodes Mapbox Vector Tiles (MVT) in Protocol Buffer format, handling geometric data and properties across multiple layers with coordinate transformation support.
Yes, if you need to work with Mapbox Vector Tiles in Python. The package is permissively licensed, has low install friction, and carries no known vulnerabilities. Maintenance is aging, so verify that the version supports your use case before committing; for active development or rapid bug fixes, check the repository's issue tracker first.
Install
mapbox-vector-tile on PyPI
pip
pip install mapbox-vector-tileuv
uv add mapbox-vector-tilepoetry
poetry add mapbox-vector-tileInstalling mapbox-vector-tile
Before you install
Low friction installation with a pure-Python wheel. Maintenance is aging—last release was over a year ago—but the repository remains active and the package has been stable since its early releases.
License in practice
MIT license permits unrestricted use, modification, and distribution with minimal legal friction.
Quickstart
pip install mapbox-vector-tile
import mapbox_vector_tile
tile_data = mapbox_vector_tile.encode([
{
"name": "layer1",
"features": [
{
"geometry": "POLYGON ((0 0, 0 1, 1 1, 1 0, 0 0))",
"properties": {"id": 1}
}
]
}
])
Geometries must have coordinates in tile-relative space (range [0, 4096)) or you must provide quantize_bounds for automatic scaling.
Verify before relying
- Whether the package handles all geometry types supported by the MVT specification, or if limitations beyond GeometryCollection exist.
- Performance characteristics when encoding or decoding large tiles or many layers.
- Whether optional pyproj dependency is required for most use cases or only for CRS transformations.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (<4.0,>=3.9) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 3 — protobuf, shapely, pyclipper |
| Maintenance | aging — 402 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 438,264/month — #6,661 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: mapbox_vector_tile-2.2.0-py3-none-any.whl
Tags
More WWW/HTTP packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
h11h11 is a pure-Python HTTP/1.1 protocol…
permissive · top 100 on PyPI
httpxHTTPX is a fully featured HTTP client library…
permissive · top 100 on PyPI
httpcoreA minimal low-level HTTP client library that…
permissive · top 100 on PyPI
aiohttpaiohttp is an async HTTP client and server…
permissive · top 100 on PyPI
geometConverts between GeoJSON, WKT/WKB, Extended…
permissive · top 5,000 on PyPI
pyGeoTileConverts between geographic coordinate systems…
permissive · top 15,000 on PyPI
polylineEncodes and decodes geographic coordinate…
unclear · top 5,000 on PyPI
geojsonEncodes, decodes, and represents GeoJSON…
permissive · top 5,000 on PyPI
utmConverts between latitude/longitude coordinates…
permissive · top 5,000 on PyPI
mercantileMercantile converts between geographic…
permissive · top 5,000 on PyPI
plpygisConverts geometries between WKB/EWKB, WKT/EWKT,…
copyleft · top 15,000 on PyPI
pygeoifPyGeoIf provides lightweight, pure-Python…
copyleft · top 15,000 on PyPI
pyvrlExposes Vector's VRL (Vector Remap Language) to…
permissive · top 15,000 on PyPI
mapboxA Python client library for Mapbox web…
permissive · top 15,000 on PyPI