How to Strava Heatmap in Gaia GPS

Alon Salant
4 min readJun 14, 2021

Living in Truckee there’s endless exploring to do. As the missions get more adventurous I’m having to level up my discovery and planning game. The Strava global heatmap is one useful discovery tool and Gaia is a great power user tool for planning routes and staying oriented when you’re out there.

This post describes the steps to show the Strava global heatmap as a map layer in Gaia so you can have both in one app.

Overview

All we’re going to do is use the Strava global heatmap tiles as the source for a custom map layer in Gaia. This works because the heatmap tile images follow the TMS URL convention used by many open mapping services like OpenStreetMap. We have to jump through a couple hoops because Strava requires that you authenticate with your Strava account in order to load the heatmap tile images.

Prerequisites

You need a Strava account to access the heatmap tiles.

To create custom map layers in Gaia you need a Gaia premium membership. When you pay for Gaia you also get access to their map catalog and features like downloading map regions for offline use.

These instructions assume you are using Google Chrome.

Step 1: Get Your Authenticated Heatmap URL

There are a few ways to do this but the easiest is to install this Chrome extension.

Open the heatmap, log in, and select the Heatmap Color and Activity Type that you want. I used the “Hot” color and “Ride” activity type. The other configuration options for the heatmap do not matter for our purposes.

Click the icon inserted into the map by the browser extension.

This will give you a TMS-formatted URL that includes authentication data tied to your Strava login. Mine looked like:

tms[3,20]:https://heatmap-external-{switch:a,b,c}.strava.com/tiles-auth/ride/hot/{zoom}/{x}/{y}.png?Key-Pair-Id=XXXX&Policy=XXXX&Signature=XXXX

(You will have authentication tokens specific to your account where I show “XXXX” above.)

To get a URL you can use in Gaia, remove the “tms[3,20]:” prefix, replace “{switch:a,b,c}” with “a”, and replace “{zoom}” with “{z}” to get:

https://heatmap-external-a.strava.com/tiles-auth/ride/hot/{z}/{x}/{y}.png?Key-Pair-Id=XXXX&Policy=XXXX&Signature=XXXX

This the the Tile Url you need for the next step.

Step 2: Add Heatmap Layer to Gaia

Open Gaia on the web.

In the left panel, navigate to Layers > Add Map Layers > Add Custom Source to view the form to add our new heatmap layer.

Name your new custom map source. “Ride Heatmap” is a good choice for this example.

Before pasting your TMS URL into the Tile URL field, we need to increase the character limit configured in the form because our URL is longer than what the form allows by default. Right click on the Tile URL input and select the “Inspect” option at the bottom of the menu to open Chrome Inspector. The Inspector will open with the HTML for that input field selected. Double click on “250” as shown below and change it to “1500”.

(I submitted a bug report/feature request to Gaia asking them to increase the limit on this field. It sounds like they might make that update which would make this step unnecessary.)

Close the Inspector and paste your TMS URL into the Tile Url field.

Increase the Zoom Range slider to the max value.

Turn on Preview on Map. If you’ve done everything correctly to this point, you will see the heat map tiles layered into the preview on the right. If you don’t See the heat map in the preview, you’ve got some debugging to so. Repeat the previous steps of n case you missed something.

Save your new custom map layer.

Step 3: Explore

Now that you have created this new map layer, you will see it in your iOS or Android app where you can display it and control its opacity. If you save a map region for offline use while the heatmap is shown, the heatmap will be saved along with the other map layers being shown.

You can create additional heatmap layers for other activity types. I have one for Ride and one for Winter.

Notes

This method of accessing the Strava heatmap tiles in other applications is documented in the OpenStreetMap project where the heatmaps are used to improve OpenStreetMap. It appears that Strava has allowed the use of the heatmap tiles for this purpose and for personal use.

Use of the heatmap data for other uses requires additional permission and licensing from Strava.

The Strava heatmap shows only shared public data from Strava users. The heatmap aggregates data over the past two years and is regenerated on roughly a monthly basis.

The authentication credentials included in your URL expire periodically — it seems to be about two weeks. You’ll need to get a new URL, remove the expired Gaia layer, and add a new layer to replace it when they expire.

--

--

Alon Salant
Alon Salant

Written by Alon Salant

Software developer and entrepreneur using my passion and skills to benefit personal health, family, community, and our planet.