Why GPS elevation gain is wrong, and what a barometer fixes
Vertical is the weakest thing a satellite receiver measures, and the way climb is totalled turns that weakness into a large, always-positive error. Why a pressure sensor is the better instrument, and where it fails too.
You ride a flat loop along a canal. The app tells you that you climbed four hundred metres. Nothing was wrong with your ride; the number was assembled in a way that guarantees it comes out too high.
Vertical is the weak axis
A satellite receiver solves for your position from the geometry of the satellites it can hear, and that geometry is fundamentally lopsided. Horizontally, satellites surround you, so errors from opposite directions partly cancel. Vertically, every satellite is above you — the earth is in the way of the ones that would be below — and there is nothing on the other side to cancel against. The result is a rule of thumb that has held for decades: vertical error is roughly two to three times horizontal error.
There is a second, separate problem. GNSS natively reports height above a mathematical ellipsoid, not above sea level, and the difference between the two varies by tens of metres around the world. Receivers apply a geoid correction, and the models differ, which is part of why two devices on the same hilltop disagree about its altitude.
Why summing makes it worse, in one direction
Elevation gain is not a measurement. It is a sum: walk through the altitude samples and add up every rise. That operation has an unfortunate property — noise contributes to it, and only ever positively.
Suppose the true altitude is dead flat and your samples wobble by a few metres each way. Every upward wobble is counted as climb. Every downward wobble is counted as nothing, because descent does not subtract from gain. Sample once a second for two hours and a sensor that is merely noisy has manufactured hundreds of metres of ascent out of a perfectly level towpath.
This is why apps apply a threshold and ignore changes smaller than some number of metres. It helps, and it introduces its own error: raise the threshold enough to suppress the noise and you also stop counting the genuine small rises that make up a rolling road.
What a barometer does differently
Every recent iPhone contains a pressure sensor. Air pressure falls with height in a well-understood way — very roughly one hectopascal per eight or nine metres near sea level — and the sensor is sensitive enough to resolve changes well under a metre.
Crucially, it is a completely independent instrument. Its errors have nothing to do with satellite geometry, urban canyons, tree cover or the geoid model, and its short-term noise is far smaller than GNSS vertical noise. For the specific job of detecting "am I going up right now", which is the only question elevation gain actually asks, it is the better sensor by a wide margin.
Roam reads the pressure sensor, stores the barometric altitude alongside the GPS one on every point, and uses the barometric value whenever there is one. Both columns are kept, so nothing is thrown away.
Where the barometer fails
It measures pressure, not height, and pressure changes for reasons that have nothing to do with you.
- Weather. A front moving through can shift sea-level pressure by ten or twenty hectopascals over a day, which reads as a hundred metres or more of apparent altitude change. Over a two-hour ride the drift is usually small; over a multi-day trek it is not.
- Absolute altitude is therefore unreliable without calibration, which is why a barometric altimeter is excellent at relative change and poor at "how high is this summit". Gain is a sum of relative changes, which is exactly the case it is good at.
- Cars, trains and aircraft are sealed enough that cabin pressure and outside pressure part company. Air conditioning in a car can register as a climb.
- A blocked port — a case, a pocket full of rain — can damp or delay readings.
Sensible practice is to use the barometer for gain and treat any single absolute altitude as approximate. On iOS the sensor also sits behind the Motion & Fitness permission, which means an app can lose access to it without anything visibly breaking.
The failure mode nobody notices
The interesting bug is not a wrong number. It is a missing one that looks like a normal one. If the barometric column is empty for a whole ride, an app that simply falls back to GPS altitude will report a plausible-looking figure, and nothing on screen indicates the good sensor was never involved.
That happened in this app’s own history: barometric altitude was null on all nine thousand points of a ride, and there was no way to tell which of five possible reasons applied — the sensor had simply never been constructed, and an absent sensor is indistinguishable from a silent one. The fix was to give each reason a name and record it as it is taken: no hardware in this device, permission never requested, permission refused, restricted by a device-management profile or parental control, switched off in the app’s own settings, or started and then failed. Those have different remedies, and two of them are a switch the rider owns.
What to do with your own numbers
- Ride a flat route and look at the reported gain. Anything above a few tens of metres over an hour on genuinely flat ground is noise being summed.
- Compare two devices on the same ride. Expect the totals to differ; expect the barometric one to be lower and more stable.
- Do not compare gain between apps as though it were a measured quantity. Different thresholds and different smoothing produce different answers from identical data.
- Treat absolute altitude as a rough figure and gain as the reliable one, which is the opposite of most people’s intuition.
Frequently asked questions
Why is my GPS elevation gain so high?
Because gain is a sum of upward changes, and vertical GPS noise contributes only upward. Every wobble up is counted as climb and every wobble down counts as nothing, so an hour of noisy samples manufactures climb on flat ground.
Is barometric elevation more accurate than GPS?
For gain, substantially — it resolves sub-metre changes and its errors are unrelated to satellite geometry. For absolute altitude it is only as good as its calibration, because weather moves the pressure it measures.
Does weather affect barometric altitude?
Yes. A passing front can shift sea-level pressure enough to read as a hundred metres or more over a day. On a short outing the drift is minor; on a multi-day trip it matters, which is why the sensor is trusted for relative change rather than absolute height.
Why do two apps report different climb for the same ride?
Different sensors, different noise thresholds and different smoothing. Gain is not a measurement but the output of an algorithm, so the same raw ride legitimately produces different totals, and comparing them across apps means very little.
A recorder that does not lose the ride
Roam commits every GPS fix to the phone the moment it arrives, marks signal gaps instead of drawing a straight line through them, and reads climb from the barometer rather than from GPS altitude. No account, no sign-in, no sync. Recording a ride, viewing it and replaying it are free.