Mapbox Traffic v1

Source ID:

This is a guide to the layers and data inside the Mapbox Traffic vector tile source to help with styling.


Mapbox Traffic provides constantly updating congestion information on top of Mapbox Streets road geometries.

When you publicly use styles or software that use Mapbox Traffic vector tiles, you must display proper attribution.

Line offsets

Mapbox Traffic can be used to display congestion for both directions on two way roads. When styling congestion, it’s recommended that you add a positive line-offset to the layer to visually separate the directions of travel.

Data updates

Mapbox Traffic receives two different types of data updates:

  • Traffic speeds and densities: used to derive congestion, updated approximately every 5 minutes
  • Road geometries: based on OpenStreetMap, periodically updated

Layer Reference

buffer: 4


The main field used for styling traffic layers is class. This contains a subset of Mapbox Streets’ road classes.

'motorway'High-speed, grade-separated highways
'motorway_link'Interchanges / on & off ramps
'trunk'Important roads that are not motorways.
'primary'A major highway linking large towns.
'secondary'A highway linking large towns.
'tertiary'A road linking small settlements, or the local centres of a large town or city.
'link'Contains link roads
'street'Standard unclassified, residential, road, and living_street road types
'service'Access roads, alleys, agricultural tracks, and other services roads. Also includes parking lot aisles, public & private driveways.


The congestion field is a measure of the relative slowdown a road segment is experiencing.