[GIS] Adding WMTS service as Basemap in Mapbox

mapboxwmts

I am trying out Mapbox and I do not see any ways to add my WMTS service as a basemap in Style in Mapbox.

Instead of using the Mapbox basemap, I will like to use a WMTS service as the basemap. There is not options to add WMTS in Tilesets. Styles only allow me to add a file or Tilesets/Datasets. I am trying to figure out how to add a WMTS to Style so that I can use it as the basemap before publishing it. I am also very new to Mapbox, trying to figure out how to use.

Best Answer

You can't add a WMTS service into a Mapbox Style in Mapbox Studio. Although the Mapbox Style Spec allows for tiled raster sources https://www.mapbox.com/mapbox-gl-js/style-spec/#sources-raster, you can't upload these to Mapbox Studio.

If you want to use Mapbox to add data on top of an existing WMTS service, then create your transparent overlay Style in Mapbox Studio and then on the client side (so in Mapbox GL JS) inject the WMTS layer into your style like in this example https://www.mapbox.com/mapbox-gl-js/example/wms/.

Related Question