Local plotting of GPX file onto Google Maps

I recorded a GPX file using myTrack HD today, and I wanted to overlay it on Google Maps. However, most of the services I’ve seen required you to upload your GPX file and they will process it for you. This is something I feel strongly against doing.

In my search for an local solution (as opposed to uploading it to a server), I found GPX Viewer, an implementation of a GPX parser in Javascript which reads the GPX file and overlays the track. This is all done without uploading any data anywhere.

All it requires is 2 files to be downloaded and it runs really well:

  • loadgpx.4.js
  • gpxviewer.html

To use it, simply download the files onto your desktop (or whichever folder you prefer), then open the gpxviewer.html file in your browser. Put the GPX file into the same folder, then append gpx=<filename> to the URL, so your URL looks like this now:


If points are too close to each other, some points may not be rendered. To overcome this, I modified gpxviewer.html to add the following lines (or modify the existing ones if you wish):


You have to add these calls before AddTrackpointsToMap() or AddWaypointsToMap(). They make the track width slightly smaller, and do not check the minimum delta between each points before it is actually plotted.

My main purpose was simply for visualization of the GPX file. I think street view and scroll wheel support would have been good.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.