0

There are plenty of pointers that show how to add WMS as a base layer in CartoDB. However, I want to add a WMS layer to the [Layer Switcher] so that it is available as a queryabl feature layer.

I was hoping this option would be available through "Add new Table" and for a source of the table we would see a WMS connector. I see ArcServer is available as a layer provider, but no generic WMS.

Am I missing something or is it simply not possible to add a WMS layer directly to a CartoDB visualisation? I could not find the point covered in their docos...

The implication of course is that we will need to somehow script an update, export/import pipeline to get some of our (often updated) data out of Geoserver and into CartoDB. Seems like a shame when there's a lovely WMS endpoint just sitting there ready to be exercised by CartoDB...if only it were possible??

  • I actually got a chance to ask Andrew Hill at CartoDB about this a few months ago. He said that it is possible to use the CartoDB Editor to create a table and then list each WMS layer in the table and add them to the web map. However, I didn't get the specifics on how exactly to do that. Since then, I've done some research on how to do in CartoDB specifically and in PostGIS more generally, but came up short in that effort. If anyone knows how to do this specifically, please let us know. – Ezra Boyd Nov 19 '15 at 21:49
4

It's not possible to add a WMS layer as a non baselayer for the moment. The workaround here is to do it client side, loading the visualization using cartodb.js and then using a WMS layer with leaflet, google maps, open layers or whatever library you are using.

Seems like a shame when there's a lovely WMS endpoint just sitting there ready to be exercised by CartoDB

There are technical implications for this obviously, if it was so easy as pointing to a WMS server it would be already possible.

When you add a layer in CartoDB it is merged with the other ones you can use fusion modes (comp-op in cartocss) so only one tile is sent to the client (instead a tile per layer). If you add a WMS layer in the middle CartoDB would need to either create different groups for merge or support the WMS layer as raster (allowing our tilers to fetch data from WMS servers and merging them with the vector data being rendered).

There are other problems, as you know not all WMS servers support web mercator so we need to pass it through a proxy to transform them to srid 3857.

  • Hey there Javisantana, thanks for the excellent insight. Of course there are technical complexities with adding a WMS layer straight into a CartoDB visualisation stack...yet I still wish it were as simple as that! – John-CapeYorkNRM Oct 20 '14 at 11:11
  • @John-CapeYorkNRM yep, we are planning to support third party layers at some point – javisantana Oct 20 '14 at 17:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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