QGIS

Accessing OS NGD data with OS NGD API – Tiles via QGIS

QGIS is an open GIS (Geospatial Information System) desktop application that allows you to display, interrogate, visualise and create geospatial information including from geo-centric APIs (for example, a Vector Tiles Service).

The instructions that follow demonstrate how to connect to OS NGD API – Tiles using QGIS.

What you'll need

Instructions

1

Set up a new connection

Once a new project with a base map map has been set up, select Layer > Add Layer > Add Vector Tile Layer.

QGIS Add Vector Tile Layer option.
QGIS Add Vector Tile Layer option.
2

Create a new connection

In the Data Source Manager | Vector Tile dialog:

  • Click New

  • Select New Generic Connection...

In the Data Source Manager | Vector Tile dialog:

  • Name: Provide a name for the connection.

  • URL: Input the Retrieve Tile request URL for the OS NGD API – Tiles collection.

  • Min. and Max. Zoom Levels: Set these as follows based on your preferred projection:

    • Web Mercator (EPSG: 3857): Min Zoom = 6; Max Zoom = 19

    • British National Grid (BNG: EPSG: 27700): Min Zoom = 0; Max Zoom = 15

  • Style URL: Input your selected style request URL; you can view the available styles at GET /collections/{collectionId}/styles.

  • Authentication: Leave these settings at their defaults.

  • Other: Leave all other settings at their defaults.

  • Click OK.

To retrieve tiles and style them appropriately, you will need two URLs. The URLs have slight variations based on the collection ID and projection.

Here are some example URLs to retrieve the basemap (ngd-base) in Web Mercator (EPSG: 3857):

To learn more about the available collections in OS NGD API – Tiles, you can view what data is available here.

QGIS New Vector Tile Connection dialog filled in
QGIS Vector Tiles Connection dialog.
3

Add layer

Navigate to Layer > Data Source Manager > Vector Tile.

In the Data Source Manager | Vector Tile dialog:

  • Select your new connection to OS NGD API – Tiles

  • Click Add.

The layer will then display in the Layers panel and the data will display on the map:

 UI showing OS NGD API – Tiles data in the Layers panel and map area.
QGIS UI showing OS NGD API – Tiles data in the Layers panel and map area.

Last updated

Was this helpful?