No plugin required
There is a core functionality XYZ Tile Server provider which was implemented with some other nice UX enhancements for tiled services (available since QGIS 2.18). This means, that there is no need for an external plugin although for an easy setup you can still use external plugins (see bottom of this post) and it offers various ...
Another plugin to add basemaps in QGIS - QuickMapServices:
QGIS Python Plugins Repository: https://plugins.qgis.org/plugins/quick_map_services/
More info about plugin:
No plugin required
Karlsson and an extension to @Matthias Kuhn's answer.
Plugins > Python Console > Show Editor
Copy&Paste the code below into a new Python file and press Run script
This script should be run from the Python consol inside QGIS.
It adds online sources to the QGIS Browser.
Each source ...
@MatthiasKuhn has provided some examples in his answer to this post: Adding Basemaps from Google or Bing in QGIS?
For Bing, you could use:
For HERE maps, you will need to register in order to obtain an APP_ID and APP_CODE which can then be used for accessing satellite map tiles via the following URL:...
If you're looking to add the ESRI basemaps to QGIS, follow the steps in this blogpost using the QGIS Python console:
Copy and paste this code into the QGIS Python Console:
Adds ESRI_Imagery_World_2D service:
Here is the code which is working for me:
urlWithParams = 'type=xyz&url=https://a.tile.openstreetmap.org/%7Bz%7D/%7Bx%7D/%7By%7D.png&zmax=19&zmin=0&crs=EPSG3857'
rlayer = QgsRasterLayer(urlWithParams, 'OpenStreetMap', 'wms')
For such cases, it is much easier to debug in a browser. You can create a web map with your tile layer and view it in a browser such as Chrome. When you open Developer Tools, you can see the failed requests in the Network tab.
I have created a simple leaflet based template using JSFiddle. You can open https://jsfiddle.net/spatialthoughts/6mz4obtw/1/ and ...
Although it doesn't appear in the "Add Layer" dialog, I can add XYZ tiles from this option in the "Browser" panel:
Right-click to add a new tile server connection, or choose one of the existing ones.
If you don't have a "Browser" panel open, use View... Panels... Browser to get one.
By the GeoWebCache documentation https://www.geowebcache.org/docs/current/services/tms.html the flipY parameter is what need.
The TMS specification has the TileGrid Map origin located at bottom left so Y coordinates grow up moving towards north. A vendor parameter “flipY=true” can be appended to the path to support Y coordinates numbered in the opposite ...
That's not because of your locale. Open Street Map uses Hebrew labels in Israel by default. According to the OSM Wiki there's no web feature service of OSM data, so you're stuck using pre-generated tile sets. As far as I can tell, OSM doesn't have a tile server with English-only labels.
You can add English labels to your map in this way:
Use the Quick OSM ...
Among the basemaps provided by the QuickMapServices plugin is a set of basemaps called "TianDiTu." According to the Wikipedia article for Tianditu, this is "China’s first official free web mapping service," created and provided by the government. That seems as solid a local solution as you could possibly get without a VPN.
The QuickMapServices plugin ...
Have you made sure your maps are using the same CRS as the tiles and conform with the zoom level default scales? (see below)
Use the Same Native CRS as Tiles
Most XYZ tiles are produced in CRS - EPSG:3857 . When using a different CRS this can skew the image and make the labels more difficult to read. See below
Conform with Zoom level default scales
The issue here was probably user error in the process of adding XYZ tiles. The issue was solved by running a python script to load the XYZ tiles.
Link to the python script:
The script was created by Klas Karlsson: https://twitter.com/...
there are several satellite base maps which can be applied to QGIS as the base map of the project and some of them are,
Google Earth Base Map
Bing Virtual Earth Base Map
Esri Base Map
please follow the following steps,
Go to Layers > Data Source Management
Go to the tab XYZ Connections
Add a New XYZ Connection
fill the name and the web URL from ...
Building on @IvanSanchez's comment, to get this to work in qgis2web, you'll have to get the contents out of the MBTiles file. Unzip the MBTiles into a directory on your website, retaining the XYZ folder structure. You can then add that location into QGIS as an XYZ layer. qgis2web will then export it.
The Difference operation is an operation that only works with vector layers (as you can see from the fact that it's located in the vector menu). You can't process any raster with that. The OpenStreetMap Layer represents raster data from raster tiles. If you want to process OpenStreetMap data with the Difference operation, you should first download OSM data ...
I've made a demo by adding first OpenStreetMap tiles (EPSG:3857) and then shapefile within file cadastre-77-parcelles-shp.zip from https://cadastre.data.gouv.fr/data/etalab-cadastre/2020-10-01/shp/departements/77/ that use EPSG:2154.
If you use the GeoJSON version e.g https://cadastre.data.gouv.fr/data/etalab-cadastre/2020-10-01/geojson/departements/77/ your ...
The MBTiles specification https://github.com/mapbox/mbtiles-spec/blob/master/1.2/spec.md does not say anything about how many pixels a tile should contain. Specification defines the grid but all that is said about the BLOB that contains the image data is that it must be either jpeg or png image and therefore a MBTiles database with 512x512 sized tiles is ...
I had this problem to when exporting an image just now and I figured it out. I just changed the DPI it's exporting at. It has nothing to do with monitor DPI as far as I know. 72 dpi worked well for me.
You can find the setting under layout > export settings > export resolution:
The coordinates for the zxy tile system are based off of the Web Mercator Projection: 3857. More information on the coordinate system is here:
You bounds are covering the whole world, and the width and height are the size of the world, when approximating a sphere.
40075016 meters is basically the circumference of the earth at the ...
The suggestion that you can get the XYZ Tiles from the "Browser" Panel is misleading since there is no panel named Browser in QGIS 3.
The only way to get this option is to open the "Add Layer" window and select the 'Browser' tab from there.
Where the browse button is in the QGIS 3.4 Data Source Manager
Shot in the dark, but a nasty little source of error: you need to remove the $ before each matrix parameter, i.e.
Note: I also omitted the domain prefix to let QGIS/the OSM server automatically choose from the available.
With help from Nyall Dawson and Givanni Manghi, there appears to be an issue with transformations with limited geographic extent and xyz tiles.
To correct the issue:
Determine the CRS of the xyz tiles for Google Satellite this is EPSG 3857 - Pseudo-Mercator.
Go to Project Properties > CRS. Select the plus button under Datum Transformations.
You can use this code to add tile layer in the map. This is a script based and to be run in the console, but you can integrate it into Plugin if that's what you are looking for.
sources = 
Seems to be a problem with the CRS of the shapefile layer.
In QGIS, it can be changed in Layer > Properties > CRS.
Changing the CRS of the layer doesn't modify the coordinates of its geometries, but the way they should be interpreted.
When you find and assign the correct CRS in which the coordinates of the geometries must be interpreted (always ...
I'm wondering that this fantastic script by Klas Karlsson has not yet been linked here:
Open your python console in QGIS (Ctrl-Alt-P or from the plugins menu), copy/paste the code from here and run: