User:Ff5722/Using Sentinel-2 imagery

From OpenStreetMap Wiki
Jump to: navigation, search

Sentinel-2 satellite data is licenced suitably to be used as background for tracing or any other purpose for OSM (licence). The best resolution available is 10 m, this is enough to trace major roads, rivers, lakes, railways etc. Pretty much the entire world is covered, and imagery is very recent (several captures per month, as recent as last week), however it can be covered in clouds, so in some cases, it is needed to use imagery of a few months old.

Sentinel-2 imagery at native resolution


I made a video guide, but it is only complementary to the process described below.

1. Download SNAP and the Sentinel-2 toolbox

2. Download data from You need to register a (free) account to download data. Login with your account, select an area on the map (try to keep the selected area small, it's best to download one tile at once) and search. The results with the green tag S2A MSI are the ones you will want. It's recommended to filter the results to show only Sentinel-2 captures, and sort by cloud cover. Download the zip package (usually around 700 MB).

Alternatively use to download granules (the unprocessed tiles are called granules).

3. Process data in SNAP (tutorial). It's recommended to place the downloaded granule on an SSD if available, to speed up the process (lots of R/W operations). Unzip the compressed folder, and open the XML file in the top level (e.g. MTD_MSIL1C.xml). Once it's visible in the left pane, right-click to open RGB view, the three colour bands will be pre-selected. Simply click OK and wait for the RGB image to be generated.Use the colour manipulation tool in the bottom left pane to ensure good contrast of roads etc.

Qgis can also open the granules, but you lose some adjustment possibilities.

4. Export processed image from SNAP. Right-click on the image, click export. Choose 'export full scene' and 'full resolution' and for filetype geoTIFF. It will take several minutes to finish on most computers.

For exporting full resolution images in SNAP you will probably need 8 GB of RAM on your system, some large granules require even more RAM available.

Use image as background

A way to get the geoTIFFs as a background layer is to and set up a WMS server at, or use Mapbox Studio to set up a custom style. You can also use the PicLayer plugin to use exported imagery directly in JOSM, but then you have to calibrate it manually each time. In the latter case, feel free to export from SNAP as JPG, this will save you a lot of disk space. Another option is using the ImportImagePlugin, which can use the location data of GeoTIFF files. However I found that it is very slow and the alignment or projection is not good.

Mapbox Studio

If you have only a few tiles to use, this is the most convenient method. However it requires uploading a 500 MB tile to Mapbox, which may take long depending on your internet connection.

  • After signing up for Mapbox, go to tilesets > New tileset > Upload > upload your geoTIFF
  • Then go to Styles > new style > pick any ('satellite', 'empty', or 'black' work best).
  • Go to your new style > edit > new layer > under 'source' select tileset > select your uploaded image.
  • Go back to your style, on the right click Share, develop & use and you will find WMTS (for JOSM) and TMS (for iD)[1] endpoints.

Thanks to 7thgrade for guiding me through the processing method

Local tileserver

This takes a bit of effort to set up the first time, but it's faster and it saves you the hassle of uploading the large files to Mapbox. If you regularly need to make custom backgrounds, it's a lot more convenient to do this locally.

See: Using local tilesets as background layer

Getting processed imagery

Should you want to trace a specific region, but you can't be bothered to process the imagery yourself, then send me a message and I will process it for you when I have time and send you the link to use as background layer.


  1. Use the url scheme for 'Leaflet'