I need to load a vector tile layer in a Leaflet map.

The vector tile is the vector tile layer about Mapillary sequences (look at https://a.mapillary.com/#vector-tiles ...), and the tile URL pattern is:


the vector tile use the Mapbox vector tile format.

I've searched on the net but I haven't found a sample: I've seen that this could be done using Mapbox, but if it's possible I'd like to use only Leaflet

2 Answers 2


In Leaflet 0.7x, this is made easy with the Leaflet.MapboxVectorTile plugin. You just need to specify the URL pattern in the url configuration option. The plugin documentation details the other configuration options that are available. To add the Mapillary data, you would use it like this:

var config = {
  url: "https://d2munx5tg0hw47.cloudfront.net/tiles/{z}/{x}/{y}.mapbox"
var mapillarySource = new L.TileLayer.MVTSource(config);

Here is a fiddle showing the result:


For Leaflet 1.0x, you will want to use Leaflet.VectorGrid's L.vectorGrid.protobuf method. It has a number of styling options described in the docs, but for just loading the tiles, you would use it like this:

var url = 'https://d2munx5tg0hw47.cloudfront.net/tiles/{z}/{x}/{y}.mapbox';
var mapillaryLayer = L.vectorGrid.protobuf(url).addTo(map);

Example fiddle:


  • Great!! it's working. Simple, clear and with example. The best!
    – Cesare
    Commented Apr 21, 2016 at 6:45
  • 5
    @nathansnider Your JSFiddle is not reachable. Would love a proper example on how to read vector-based tiles with leaflet
    – LBes
    Commented Aug 14, 2018 at 15:08
  • 2
    Anything for Leaflet v3+ react + typescript? Commented Aug 29, 2022 at 14:51
  • The plugin referred to here (leaflet-mapbox-vector-tile) has 21 weekly downloads in 2024 and was last published 9 years ago, see npmjs.com/package/leaflet-mapbox-vector-tile Commented Mar 2 at 16:40
  • And the other plugin referred to here (leaflet.vectorgrid) has 5980 weekly downloads in 2024 and was last published 7 years ago, see npmjs.com/package/leaflet.vectorgrid Commented Mar 2 at 17:22

See the list of Leaflet plugins for vector tiles. Note that MapboxVectorTile and hoverboard work only with Leaflet 0.7.x, which will be deprecated by Leaflet 1 "Really Soon™".

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.