Draw. Edit. Export Español
← Back to GEPYX

GEPYX Guides

How Elevation Gain Is Calculated (And Why Every App Gives You a Different Number)

Elevation profile of a mountain route

You walk a route, upload it to two platforms and get two elevation figures 300 metres apart. It is not your mistake, and it is not your GPS: elevation gain is not measured, it is calculated, and every application calculates it its own way.

What cumulative elevation gain actually is

Positive elevation gain is the sum of every climb along a route, ignoring the descents. If you climb 100 metres, drop 40 and climb another 60, your cumulative gain is 160 metres, even though the difference between the trailhead and the summit is only 120.

It is the number that best describes how hard a route really is, far more than distance. Twelve flat kilometres and twelve kilometres with 1,200 metres of climbing have nothing in common.

How it is calculated from a GPX

The basic recipe is simple: walk through the track points one by one, subtract each point's altitude from the previous one, and add up only the positive differences. Do exactly that, and you get an enormous, completely false number. This is where the trouble starts.

Why the naive calculation fails

Altitude data comes with noise. A GPS has a typical vertical error of several metres, and that error fluctuates constantly even when you are standing still. If your track stores one point per second for six hours, you have more than 20,000 points, and every tiny upward wobble gets added to the total.

The result is that a perfectly flat route can report hundreds of metres of invented elevation gain. That is why every application applies some kind of filter before summing.

Open your GPX and look at the real elevation profile, point by point.

Open the GEPYX editor

The three filters each app uses (and why they disagree)

Barometric altimeter versus GPS altitude

High-end watches include a barometer, which infers altitude from atmospheric pressure. It is far more precise at detecting small changes, but it has a well-known weakness: it reacts to the weather. If a front moves in and pressure drops while you walk, your watch will think you climbed without moving at all. A storm can add a hundred phantom metres to the day.

GPS altitude does not suffer from that, but it is much noisier. And a digital elevation model is stable and clean, but it does not know whether you were on a bridge, in a tunnel or at the bottom of the gorge.

Which number should you trust

None of them is absolute truth, which is why the useful approach is consistency: always compare using the same tool. If you know your watch systematically reads 15 % higher than the reference you plan with, you have your own correction factor — which is worth more than arguing about which app is right.

In GEPYX the elevation profile is computed with smoothing tuned for mountain routes: it filters noise without swallowing the real short climbs. You can open the same GPX you uploaded elsewhere and see where the difference comes from, section by section.

Once you have a reliable gain figure, you can estimate how long the route will take: we cover that in how to estimate hiking time.

Got a track to fix, or a route to plan for next weekend?

Open the GEPYX editor