Friday, August 08, 2014

How to Export and Save a Route or Track from Garmin Connect

Download gpx, tcx, fit, json, or gpolyline from the Garmin Connect Website


You can view routes and tracks online at Garmin's connect website, but it is not obvious how you  download a copy. Here's how to do it.

Look at the URL or web address of the Garmin Connect webpage. It should look something like this:

http://connect.garmin.com/course/3220309

(This particular route is the Clonakilty Waterfront Marathon, but use whichever one you want.)

The part of the URL that you need is the string of numbers at the end, 3220309 in this case. Swap the numbers for the course you want into the links below to download the file.

JSON: http://connect.garmin.com/proxy/course-service-1.0/json/course/3220309
FIT: http://connect.garmin.com/proxy/course-service-1.0/fit/course/3220309
TCX: http://connect.garmin.com/proxy/course-service-1.0/tcx/course/3220309
GPX: http://connect.garmin.com/proxy/course-service-1.0/gpx/course/3220309
GPOLYLINE: http://connect.garmin.com/proxy/course-service-1.0/gpolyline/course/3220309

UPDATE June 2015: The exported data may lose elevation and other details. This seems to be a wider issue with Garmin Connect exports. See this thread for more details: https://forums.garmin.com/showthread.php?229674-Exporting-data-to-tcx-or-gpx-NO-elevation-data

12 comments:

Magui said...

genius!

Al Heeley said...

Nice, but I lost all the elevation data in the export?

The Skanger said...

Hi Al, I'm not sure why that's happening, but it may be a wider Garmin Connect issue:

https://forums.garmin.com/showthread.php?229674-Exporting-data-to-tcx-or-gpx-NO-elevation-data

Johannes said...

Thanks for these pointers. I've created a simple Greasemonkey user script which adds those links to the Garmin Connect page.

The script is on https://github.com/johannes/garmin-connect-gmscripts/raw/master/garmin-connect-course-export.user.js

Learn more about Greasemonkey via https://en.wikipedia.org/wiki/Greasemonkey

Luis Miguel said...

Greate Info! thansk a Lot!

Anonymous said...

great info. gpx export does not seem to work as gpx. exports tcx.

Troy Bannon said...

Thank you so much! After hours of trying garmin help, manuals, loading software, different cables... so much frustration solved by your excellent solution! Shame on Garmin for such lazy ineffective software!

Rainer Schütt said...

I discovered that this does only work if the course exists in the modern as well as in the classic environment. The courses that have been created after a certain time only seem to exist in the modern environment. When trying the URL with the course-id it results in an empty page with no error-message. Does a simular solution exist that downloads courses that only exist in the modern environment?

Anonymous said...

I had the same problem as Rainer Schütt. But then I found that there is another solution to download the data. When you have opened the activity details page, there is a tiny little cogwheel in the upper right corner. Click on it and a menu will open that offers a couple of download options.

Rainer Schütt said...

Yes, but only for Activities. In Courses the only download-options are the one that send the bitmap to some social-media.
In the meantime I found another solution that works, even for courses that only exist in the modern-environment. Just go to this site:

http://gotoes.org/strava/Export_GPX_File_From_Garmin_Connect_Course.php

From there drag the "Export CRS As GPX"-box to your bookmarks or copy and paste the URL.

If you then go to a course in Garmin-Connect open the details and then click the bookmark you created. This will execute a javascript that automatically downloads the route as a GPX.

The Skanger said...

Hello Rainer,

The bookmark you linked to runs javascript that generates exactly the same URL as mentioned in the original post, i.e., it uses http://connect.garmin.com/proxy/course-service-1.0/gpx/course/ to download the GPX file by adding the identifying number for the course you're on when you click the bookmark.

So, when I go to this course, which is relatively recent (28 April 2016),

https://connect.garmin.com/modern/course/12221309

clicking the bookmark loads this page

http://connect.garmin.com/proxy/course-service-1.0/gpx/course/12221309

and starts a download of the GPX file.

I can't explain why the bookmark works for you while entering the same URL directly doesn't.

I tried directly entering variant URLs with the same course. All of these generate downloads for me:

http://connect.garmin.com/proxy/course-service-1.0/gpx/course/12221309
http://connect.garmin.com/proxy/course-service-1.0/tcx/course/12221309
http://connect.garmin.com/proxy/course-service-1.0/fit/course/12221309
http://connect.garmin.com/proxy/course-service-1.0/json/course/12221309
http://connect.garmin.com/proxy/course-service-1.0/gpolyline/course/12221309

In fact, if I edit the link in the bookmark and put tcx in place of gpx, clicking the bookmark initiates download of a TCX file.

Rainer Schütt said...

You are right! On my Mac it works perfect. Initially I tested this om my iPad and for some reason this did only work for courses that were from the time that I could choose between modern and the older environment. The version with the Java-script was only tested on the Mac. So, the conclusion is to always use the Mac (or PC) for this.

Many thanks!