GPS Files: A Field Guide

A story about tracks, timestamps, and turning messy data into clean routes.

Published 2025-09-05 • Reading time ~10–12 min

Prologue: the trail in your pocket

Every run, ride, hike, and flight leaves breadcrumbs: latitude, longitude, sometimes elevation, often time. Different apps write those breadcrumbs in different diaries: GPX, TCX, KML, or humble CSV/XLSX. The problem isn’t the data — it’s the dialect. This guide shows what each format means, how to translate between them, and how to use the GPS tool’s map, stats, and splits like a pro.

The formats, as travelers

GPX (the hiker)

XML for tracks. A GPX track is a list of points: <trkpt lat="…" lon="…"><ele/><time/></trkpt>. Simple, portable, understood by most devices and apps.

TCX (the coach)

Garmin’s training schema. Adds structure (laps, activities). Points live in <Trackpoint> with LatitudeDegrees, LongitudeDegrees, AltitudeMeters, and Time.

KML (the mapmaker)

Google Earth’s language. Routes often appear as <LineString><coordinates>lon,lat,ele …</coordinates>, or as gx:Track with timestamps.

CSV / XLSX (the spreadsheet)

Tables of points. Flexible but ambiguous until you map columns: lat, lon, ele, time.

Anatomy of a point

  • lat — latitude, degrees north/south of the equator.
  • lon — longitude, degrees east/west of Greenwich.
  • ele — elevation in meters (optional).
  • time — timestamp; ISO 8601 (2025-01-01T10:00:00Z) is the cleanest. Unix seconds/ms and Excel serial dates also work.

Distance between points is computed with the haversine formula over a spherical Earth (we use 6,371,000 m). Elevation gain and loss are the sum of positive/negative elevation differences. From distance and elapsed time we compute speed and pace (e.g., 5:30 / km).

Using the GPS tool (step by step)

  1. Load data — click Load GPS Data and choose a .gpx, .tcx, .kml, .csv, or .xlsx, or paste the raw text.
  2. Field Mapping (CSV/XLSX) — the tool guesses columns, you can correct them. Time formats: Auto/ISO, Unix seconds, Unix ms, Excel serial.
  3. Parse — the preview table appears; the map draws your route with start/end markers.
  4. Map — pick a base map (OpenStreetMap, Satellite, Toner). Use Fit to Track to zoom to your route. Hover the map to see the nearest point’s distance, elevation, and time.
  5. Stats — choose units (km/mi). See total distance, elapsed time, avg speed, elevation gain/loss, min/max.
  6. Splits — choose “Split every” (e.g., 1 km or 1 mi) and click Recompute. Each split shows distance, time, pace.
  7. Export — select GPX/TCX/KML/CSV/XLSX and download a clean file.

Mini examples

CSV → GPX

lat,lon,ele,time
37.7749,-122.4194,12,2024-01-01T10:00:00Z
37.7755,-122.4188,13,2024-01-01T10:05:00Z

Load the CSV, map columns if needed, parse, then export as GPX.

KML → TCX

<LineString>
  <coordinates>-122.4194,37.7749,12 -122.4188,37.7755,13</coordinates>
</LineString>

Paste KML, parse, export as TCX for training platforms that prefer it.

Terms decoded

  • Waypoint / Route / Track — single points (WPT), planned path (RTE), recorded path (TRK).
  • CRS/Projection — we assume WGS84 lat/lon (EPSG:4326). Don’t feed projected coordinates into lat/lon.
  • Time zone — timestamps are stored as absolute times (UTC in ISO with Z); local display depends on your device.
  • Smoothing — jittery elevation or GPS noise can inflate gain; basic smoothing helps (planned future toggle).

Troubleshooting

  • Nothing draws on the map: Check lat/lon columns (CSV/XLSX) and that values are numeric.
  • Distance is zero: You may have identical points or swapped lat/lon. Ensure lat is latitude (−90…90) and lon is longitude (−180…180).
  • Times look wrong: Make sure the time format matches (Auto/ISO, Unix, Excel). Excel serial dates need the “Excel” option.
  • KML without times: We compute distance/speed anyway; splits with pace require timestamps.
Pro tip: Keep your raw files (original GPX/TCX/KML) as a backup. Convert and share CSV/XLSX for analysis, GPX/TCX for fitness apps, and KML for map viewers.