Repairing a Workout Using a Reference GPX File
By Roy Lachica on . Last updated .
Sometimes the best source of truth for a broken recording is not your own file, it is someone else's. A race organizer's published course, a training partner's clean recording of the same route, or your own GPX from a previous lap of the same trail can all be used as a reference to repair a track that lost signal, wandered off course, or recorded a section badly. This post covers when that approach makes sense and how GpxFix uses a reference file to fix it.
When you would reach for a reference file
- Your watch dropped a section entirely. A tunnel, a dense forest, or a battery restart left a gap in your track with no coordinates at all for several minutes.
- The route organizer already published the course. Trail races and organized rides, UTMB among them, often provide an official GPX of the exact course, which is more reliable than trying to reconstruct your own missing section from scratch.
- Someone else recorded the same route cleanly. A training partner's file from the same run, or your own recording of the same trail from an earlier date, works just as well as an official course file.
- Your GPS drifted rather than dropped out. The track never went missing, but it wanders 50 meters off the actual road or trail for a stretch, a pattern common in urban canyons or under thick tree cover.
Two different repairs, both using a reference file
Filling a missing segment
When your file has a genuine gap, no track points at all for a stretch of time, GpxFix looks at the reference file's points for that same time range and extracts the matching section. Because the reference file was recorded on the actual course you were following, the inserted points follow the real route rather than a straight line guess between where you lost signal and where you picked it back up. Speed and distance for the reconstructed section come from the reference track directly.
Pulling a wandering track back onto the route
When your file has points the whole way through but they drift off the real path, GpxFix's smooth toward reference mode compares every point in your track against the reference line. Any point that has drifted more than 10 meters from the reference is pulled back toward it, GPS speed spikes are detected and snapped onto the reference line rather than left as outliers, and a final smoothing pass removes any residual jitter so the corrected track does not look artificially stitched together.
What makes a good reference file
- Same physical route: the closer the reference course matches what you actually ran, rode, or hiked, the better the repair. A reference that shortcuts a switchback you took will import that shortcut into your file.
- Reasonable time alignment for gap filling: when filling a missing time-based gap, GpxFix matches by the corresponding time range, so a reference recorded at roughly the same pace as your own activity produces the most natural result. A race organizer's course file or a same-day training partner's recording both work well for this.
- Clean GPS itself: a reference file that has its own spikes or drift will pass those problems into your repaired track, so it helps to run the reference through a quick GPS check first if you are unsure of its quality.
Workflow with GpxFix:
- Upload your own recording as the file to fix.
- Upload the race organizer's official course GPX as the reference file.
- Run the repair, GpxFix identifies the missing section after 8km and fills it using the matching portion of the official course.
- Review the map to confirm the reconstructed section follows the actual trail, then download the completed file.
How this differs from automatic gap reconstruction
GpxFix can also rebuild a missing section without any reference file at all, by using your own out-and-back or repeated-loop data from elsewhere in the same activity. A reference file is the better option whenever you have access to a genuinely separate, reliable recording of the same course, since it repairs the gap using real data rather than inferring a route from the shape of your own track.
Frequently asked questions
Does the reference file need to be from the exact same day?
No, but it should follow the same physical route. A reference recorded on a different day at a similar pace works well for filling a missing time-based gap.
Can I use a reference file just to clean up drift, without any missing sections?
Yes. The smooth toward reference mode works on tracks that have no gaps at all, it corrects position drift and speed spikes by pulling the track back onto the reference line.
What file types can I use as the reference?
GpxFix accepts GPX, FIT, and TCX files as the reference upload, the same formats it accepts for the activity you are repairing.
Got a broken recording and a reference file for the same route? Upload both to GpxFix and let it match the good data to the gap. Related reading: restoring missing GPS data.
Other blog posts
- Heart Rate Stuck at One Flat Value: Causes and How to Fix It
- GPS Freezes Then Jumps: Why Your Watch Shows Impossible Speed Spikes
- TCX to GPX: Why Convert a Garmin Training Center File and How It Works
- Snap to Road: Aligning a Wandering GPS Track to the Real Route
- How Wind Turbines Can Interfere with GPS Signals
- Why Your Strava Activity Got Flagged And How to Fix It
- Why Setting the Correct Activity Type is Essential
- How to Adjust the Start Time of Your Activity
- How to Calibrate Elevation in Your GPX File
- GpxFix Blog
- How to Resample and Simplify Your GPX File
- How to Reverse the Direction of Your GPX Route
- How to Adjust Speed and Pace in Your GPX File
- How to Fix Common Strava Upload Errors
- How to Fix Incorrect Heart Rate Data in Your GPX File
- Understanding and Fixing Saw-Pattern GPS Tracks
- Understanding GPS Spike Zones: Identifying and Analyzing Erroneous GPS Data
- Heart Rate Data Missing or Corrupted in Your GPX File — Causes and Fixes
- How to Anonymize a GPX File Before Sharing It Online
- Why Your Elevation Gain Is Wrong And How to Fix It
- How to Fix a Workout When You Forgot to Resume a Paused Watch
- How to increase the distance of a Strava Activity after watch died
- Why you should skip the headphones on trail runs and races
- Tips for Recording Video While Racing — Camera Options, Battery Life, and More
- How to Create a Hyperlapse Video for Your GPX Route
- GPX Files with YouTube Video Segments: A New Way to Experience Routes
- To Pause or Not to Pause
- GPS & Elevation Accuracy Showdown 2026 | Garmin vs COROS vs the Rest
- Why Garmin and Strava Sometimes Show Different Distances for the Same Workout
- Why Your Activity Distance Is Wrong And How to Correct It
- Fixing Broken Strava Activities
- Why Some Workouts Cannot Be Fixed
- How to Get a GPX File onto Your Garmin Sports Watch
- How to Combine Multiple Runs Into One Activity
- How to removes GPS Spikes or extreme sudden movements
- Why We Are Introducing Subscription
- Comparing activities - a practical guide
- How GpxFix Reconstructs Indoor Track Runs — even when GPS drops out
- How to restore missing GPS data
- Crop & Cut GPX Activities — A Practical Guide
- How to Change the Distance of a Workout
- When Is It Okay, and Not Okay, to Alter Elapsed Time
- How to Change Moving Time to Match Elapsed Time
- On the Ethics Of Editing Fitness Data
- Understanding Elapsed vs. Moving Time in Strava
- How to Get Accurate GPS and Heart Rate Data

