xyz to QGIS

Using OpenStreetMap Basemaps with QGIS 3.0

QGIS 3 is a new wave of open source GIS. Not only is it extremely quick and efficient, allowing you to use almost every type of geospatial data you can throw at it, but it also includes a 3D renderer and ways to export your creations straight to the web. And let’s not forget the HUGE amount of tools it comes with out of the box.

But it has only been out a couple of days and is missing the good old “Quick Map Tools” which we have all become accustomed to, allowing us to easily bring in OpenStreetMap, Stamen, and other background maps with ease. You may have read that you can enable them by using xyz tiles, but, if you are like me, this might as well say, “Stick cheese in your keyboard and twiddle it a little.” As an average GIS user, I have no idea what an xyz tile server is, and, unless you need one, you probably won’t know either. So good news: I’ve put together a little blog for you to get your services back with ease.

Here’s how:
1 – Go to 

                                                                             Open the OSM wiki
2 – You’ll see that there is a column “tiles url.” These are the xyz tile web addresses you need to make this work.

                                                                               xyz tile addresses
3 – Open QGIS (3.0) and ensure your browser window is open. You will see the xyz tile option about three-quarters the way down the list.

                                                                           xyz tile option

4 – Select the “new connection” option, and, you guessed it, we are going to use the information from the web page and put it into the relevant boxes. ONE IMPORTANT NOTE: Ensure you remove the “$” symbols before copy and pasting them over.

5 – Click okay, and away you go! 


Now that you know how, you can go through the list and add the rest of the services.

Layer xyz web URL
OpenStreetMap’sÿStandard tile layer${z}/${x}/${y}.png OR${z}/${x}/${y}.png OR${z}/${x}/${y}.png
Wikimedia Maps${z}/${x}/${y}.png
OpenCycleMap${z}/${x}/${y}.png OR${z}/${x}/${y}.png
Humanitarian map style${z}/${x}/${y}.png OR${z}/${x}/${y}.png
OSM France${z}/${x}/${y}.png OR${z}/${x}/${y}.png OR${z}/${x}/${y}.png
Cycling routes${z}/${x}/${y}.png
Hike & Bike${z}/${x}/${y}.png
OSM B&W${z}/${x}/${y}.png or${z}/${x}/${y}.png OR${z}/${x}/${y}.png OR${z}/${x}/${y}.png
OSM no labels${z}/${x}/${y}.png or${z}/${x}/${y}.png OR${z}/${x}/${y}.png OR${z}/${x}/${y}.png
Stamen Toner${z}/${x}/${y}.png
Stamen Watercolor${z}/${x}/${y}.jpg
Transport Map${z}/${x}/${y}.png OR${z}/${x}/${y}.png
Thunderforest Landscape${z}/${x}/${y}.png OR${z}/${x}/${y}.png OR${z}/${x}/${y}.png
Thunderforest Outdoors${z}/${x}/${y}.png OR${z}/${x}/${y}.png OR${z}/${x}/${y}.png
CartoÿLight (“Positron”) https://cartodb-basemaps-{s}{z}/{x}/{y}.png
CartoÿDark (“Dark Matter”) https://cartodb-basemaps-{s}{z}/{x}/{y}.png
OpenRailwayMap${z}/${x}/${y}.png OR${z}/${x}/${y}.png OR${z}/${x}/${y}.png

Here is a list so that you can copy and paste them directly 🙂


Using OpenStreetMap Basemaps with QGIS 3.0” Comments

  1. Hi,
    I can’t display “CartoÿLight (“Positron”)”.
    Do you have any solutions to use it ?

    Thanks you !


  2. Hi,
    It was working when I posted it, but checking it today, I can see it doesn’t work.
    I tried a few things to get it working again and nothing really nudged it into life BUT I DID find this clever script from Klas Karlsson here:
    Open QGIS 3, find your python console (normally 3rd row down to the right), open it and then copy & paste this script in…..when you refresh your catalog/browser pane, all the connections will be in there and working!!
    No more need to enter all the info one by one!

    • Andi

      Now it works. Thank you 🙂

  3. The tiles layer loads fine however the text renders too small for me to see it! Any idea why that might be??

    • Colin

      I’ve done some further testing. It appears that QGIS 3.0 does not correctly render base maps like OSM on High DPI (3200×1900) monitors…

    • Hi Colin,
      I’m currently looking into this, it might be an issue with high resolution or large displays. Where the data is served as tiles they normally scale well for both mobile and desktop screens do you have any screenshots or info on the screen and resolution you are using?

  4. Thanks so much! Really useful!

  5. Hi Colin, having looked into this further, I can confirm it is an issue with the high resolution, this is due to the high number of pixels. As far as I can see, this is a known issue which OSM are looking at but in the meanwhile, unless you specifically require vectortiles, you could use the WMS or raw data.

  6. Hi Nicholas,
    Thanks for your replay.
    I’m currently using a Lenovo Yoga 900 with 3200×1900 resolution.
    I can send you screen shots. If you email me then I’ll send them through.
    I’m looking at other work-arounds but we use QGIS in a production environment so we are limited by our IT department to a standard install. It has been suggest to build our own server and use vector tiles but building our own map server isn’t feasible. -_-

  7. Sir, I’m trying to load Tamil Nadu map in qgis 3
    i loaded it using xyz tiles using in-built openstreetmap plugin after clicking that my server is not able to load the tile.
    It is showing like getting tiles for long time and atlast it is displaying like “A network disconnected any data trying to load is incomplete” error.
    Help me with this sir!

  8. Thanks, Nicholas!

  9. I installed QGis 3.0.1-Girona on April 6th and it looks like there’s an OpenStreetMap item (with URL “{z}/{x}/{y}.png”) in the XYZ Tiles section added by default.

  10. […] is an article on xyHt published about how different OpenStreetMap tiles can easily be integrated into QGIS […]

  11. […] OSM und Place Search für 3.0 […]

  12. Thanks for this useful guide. I prepared map and in the layout it shows all city and country names but in the exported image the country name doesn’t appear. The city and place names are too small to be visible. Is there any adjustment of city/place name size possible?

  13. Hey, Thanks for the valuable guidance- Does anyone know how to change the language of OSM maps [street/road/mountain etc. names] in QGIS 3.0.2 instead of having the country language e.g. all in english? I found the QuickMapServices plugin as an option..but in vain! Anything to add to this problem?

    Thank you in advance,


  14. Hello: Nicholas, this article saved me hours of QGIS searching. Wondering if you had any suggestions for Geological Data in the USA from the Au, Ag Prospectors point of view…?

  15. Hello Nicholas,

    Great article. I love the access to the XYZ tile formulas. I found several that are useful to me.

    I am wondering if there is a formula that pulls just streets (and maybe street names) from OSM. I really like the B&W one you included but that pulls buildings, parks, etc. I’m looking for some way to just get clean street maps with QGIS.


  16. Great post,
    thanks for your effort.


  17. Fantastic, thank you so much!

Leave a Reply

Your email address will not be published. Required fields are marked *