Skip to content

How OnTrace works: from your GPX file to every water point

The presentation film, then how it all works: open sources, the kilometer of each place, the dry stretch, reliability, camping zones and privacy.

By Julien16 min read

You have a GPX file and a simple question: where to drink, sleep and eat along this route? OnTrace answers in a few seconds, each place at its kilometer. Behind that answer are open data sources, geographic calculations, trust rules and many deliberate choices, including saying “nobody knows” rather than guessing.

This post opens the hood, in detail. It is for people planning a long walk who want to know what what they read is worth, for organizers wondering whether they can rely on it for a race, and for the curious who want to understand how a trace becomes a list of water points. Start with the presentation film: 80 seconds, chapter by chapter.

The OnTrace presentation film, from importing a trace to exporting it to your watch. On-screen text in French, with English subtitles.

Note

The film was made in early October. Two things have changed since: page visits are now counted, without cookies and without following you from one day to the next, and OnTrace can also build a route without a GPX file. The rest of this post describes the app as it is today.

In one sentence#

OnTrace reads your trace, queries open databases over a strip of ground around it, keeps what is really within reach and sorts it in route order, along with what walkers have reported lately.

Everything else follows from that idea: the list by the kilometer, the longest stretch without water, the profile, the camping zones, transport, planning together and exporting to your watch. Here is the path of a trace, step by step:

  1. Reading the file, checking it is in France, adding the altitude if it is missing.
  2. Splitting the ground around the trace into squares, read from the cache or asked of the sources.
  3. Merging the sources, removing duplicates, working out each place’s distance from the trace and its kilometer.
  4. Reading walkers’ reports and working out a confidence level for each place.
  5. Showing it all: the list in route order, the map, the profile, the dry stretch, the zones crossed.

1. Importing a trace#

You drop a GPX file and choose a search radius, from 100 meters to 10 kilometers around the trace, one kilometer by default. The file is read as a stream, point after point, which takes traces of several hundred kilometers in its stride.

If the file has no altitude, like a trace drawn by hand on a mapping site, OnTrace asks the IGN elevation service for the altitude of the ground during the place search, at the same time, at no extra wait. You still get a profile, ascent and descent, and the lowest and highest altitudes.

No account is needed to search, and an anonymous search is not kept. The trace is only saved if you decide to share it.

Important

OnTrace works in mainland France and Corsica. A trace that crosses the border is still accepted as long as at least a fifth of its length is in France, which lets the Tour du Mont Blanc through. A trace entirely abroad is turned down with a clear message, rather than a half-empty map.

2. Choosing what to look for#

OnTrace knows 24 kinds of places, sorted into six families. What matters most for walking self-sufficient is ticked in advance, and your choice is kept from one visit to the next.

FamilyKinds of places
Water and hygieneWater point, cemetery (likely water), toilets
Shelter and lodgingStaffed hut, unstaffed cabin, gîte, shelter, campsite, lodging
SuppliesCafé or bar, restaurant, food shop
Services and safetyPharmacy, cash machine, defibrillator, tricky passage
TransportTrain station, coach station, metro, tram stop, bus stop
DiscoveryViewpoint, picnic spot, cave

Ticked by default: water points, cemeteries, toilets, staffed huts, cabins, shelters, tricky passages and viewpoints.

The server always fetches every kind of place on the ground covered, but only sends you the ones you ticked. Showing stations or pharmacies as well costs no new request to the sources, and appears in one click.

3. Where places come from#

Places come from three open sources, each for what it does best:

  • OpenStreetMap, the worldwide collaborative map, queried through its Overpass query service, for drinking water, shops, services, health and transport stops.
  • refuges.info, run by mountain people, for huts, cabins, gîtes and mountain water points, with their state when it is known.
  • Transitous, which brings together the timetables of transport networks, regional coaches across France included, for the stops OpenStreetMap does not have, lines and next departures.

The same place is often known to two sources. OnTrace shows it once, by precise rules:

  • Between OpenStreetMap and refuges.info, less than 30 meters apart and of the same kind, the refuges.info entry stays: it has a proper name, photos and comments from mountain people.
  • For a stop known both to OpenStreetMap and to the Transitous timetables, the tolerance rises to 60 meters and the OpenStreetMap entry stays.

To recognize a place on the ground, its card shows the OpenStreetMap photo when there is one, otherwise the nearest one on Wikimedia Commons, its GPS coordinates to copy and a link to Google Maps. Photos come from third-party sites: they only load with your consent.

The OnTrace map with a trace, its places and the elevation profileThe trace, its places grouped when close, and the profile below the map

4. A cache per square of ground#

Querying these sources for every search would be slow, and unkind to free services run by volunteers. So OnTrace splits the country into squares a few kilometers wide (a twentieth of a degree, about 5.5 km from north to south) and keeps each square’s result for seven days.

  • An area already seen shows at once.
  • An older area shows at once too, then updates in the background, once the answer has gone. Two updates of the same square never run at the same time.
  • Only an area never seen makes you wait for the source.

For a very long trace, OnTrace keeps only a few hundred points to draw the search corridor, and turns down a search that would ask for more than 400 squares at once, rather than overloading the sources.

Good to know

When a source does not answer for part of the trace, OnTrace says so in plain words instead of quietly showing fewer places. It happened several days in a row in October, when the public OpenStreetMap servers were overloaded: areas already cached were still served, the others were flagged as incomplete.

5. The kilometer of each place#

This is what changes planning the most. For each place, OnTrace finds the closest point of the trace, then measures the distance from the start to that point. If the trace passes the same place again, as on a loop or an out and back, the closest pass counts.

The list then reads in route order, like a roadbook. You can also sort it by distance from the trace, to see first what is on the way. Each place shows both figures side by side: a water point 800 meters off the path is not worth the same as a fountain by the path, even at the same kilometer.

Around the start and the finish, often in town, the map can fill up with shops: an option hides those surroundings to keep what matters readable.

6. The longest stretch without water#

From the list by the kilometer, OnTrace finds the longest section between two usable water sources, start and finish included. It is drawn as an orange dashed line on the map and the profile, with its first and last kilometers.

  • Counted as sources: drinking water points and cemeteries, which almost always have a tap.
  • Not counted: a water point walkers reported dry or not drinkable, and a place the source no longer returns, which may be gone.

The calculation runs again as soon as a report comes in: a fountain reported dry today lengthens the stretch at once, for everyone.

7. How reliable each place is#

“There is a fountain” does not say whether it runs in August. So anyone signed in can report the state of a place, whatever its kind, with the date it was seen (up to 60 days back) and a public note. The states offered depend on the place: running, dry or not drinkable for water, open, full or closed for a hut or a shop, working or out of order for equipment, passable or not for a passage.

A reliability level (confirmed, mixed reports or reported) and a confidence (low, medium or high) follow, from rules written in black and white:

  1. Each person counts once, however many reports they make.
  2. A recent finding weighs more than an old one. A report’s weight halves with each “half-life”, which depends on the kind of place. Beyond six months, nothing counts any more.
  3. Bad news weighs a little more than good news, a quarter more: better a needless check than a dry tap.
  4. An account created the day before weighs half as much, and a regular contributor, signed up for more than three months with at least five reports, a little more. Age alone is not enough: it is earned with findings.
Kind of placeA report loses half its weight in
Water point, cemetery14 days
Staffed hut, cabin, gîte30 days
Shelter45 days
Toilets60 days

Before the first report, OnTrace relies on what the sources themselves say, like seasonal opening hours in OpenStreetMap or a cabin’s state on refuges.info, without ever passing it off as a walker’s report. And when the latest finding on a place is more than two months old, the trace summary counts it among the places to check again, and asks whoever passes by for news.

8. The map and the profile#

The map is made to be read at a glance, at a desk as on a phone:

  • Three base maps: the IGN map with relief shading, by default, the OpenTopoMap Relief map, and IGN aerial photos with place names.
  • The route in crimson on a white casing, thicker as you zoom in, direction arrows when zoomed in, and kilometer marks spaced to suit the zoom.
  • Hovering the trace (or touching it on a phone) shows the kilometer and the altitude of that point.
  • Nearby places group into badges ringed with the colours of their families, so a town does not drown the map. An orange dot shows that a place your team commented on is inside.
  • The profile gives ascent, altitudes, water points all along the route and the dry stretch. Hover it to find the spot on the map.
  • The type of ground, on request, gives the share of road and path along the route, from the OpenStreetMap ways within 30 meters of the trace.

9. Camping and protected areas#

Zones drawn on the map show where camping is allowed, tolerated, restricted or forbidden, where national parks, regional nature parks and nature reserves begin, and where livestock guard dogs watch flocks.

They come from several places:

  • the public files of the national parks,
  • the national natural heritage inventory, read through the IGN Géoplateforme: regional nature parks, national and regional nature reserves, biological reserves, biotope protection orders,
  • contributors, each of whose zones is reviewed by the team, and which anyone can flag if it is wrong.

Each zone has a calendar, to the day and month, without a year: a ban may only hold in summer, a tolerance only out of season. A rule without a period holds all year. On your trace, OnTrace lists the zones crossed or passed near, with the kilometer, the length walked inside and the periods, and puts a ban first.

You can also draw your own zones for a trace, seen by you alone or by your whole team.

Camping and protected area zones on the mapEach zone has its status and its calendar

Watch out

Where nothing is drawn, nobody knows. No zone never means anything goes. OnTrace would rather say so than let you believe otherwise.

10. Getting on and off the trace#

Bus, tram and metro stops and stations are places like any other. Each stop’s lines are read with the stops and kept for seven days: a stop served by a single line shows its number right on the map, without asking for anything more.

Open a stop: its lines show in colour, each with its terminus (“To Argentière”), then the next departures, and real time when the network gives it. Timetables are only asked for at that moment, for that stop alone. When no timetable is published, the card says so rather than making up a frequency.

A transport stop with its lines and next departuresA stop’s lines, their direction and the next departures

11. Weather and warnings#

Choose a start date and time, up to seven days ahead: OnTrace gives the forecast at several points of the route (sky, temperature, wind and gusts, chance of rain), adjusted to the real altitude of each point when the profile knows it. Forecasts come from Open-Meteo, which only receives a few points of the trace with a date and time.

When they are available, the Météo-France warning for the département and the avalanche risk bulletin for the massif are added. The same start time is used for opening hours on a place’s card.

Note

The weather is given at the start time for every point, not at the time you will get there: that time depends too much on slope and terrain to be guessed honestly.

12. Planning together#

Once the search is done, you can save the trace under a name and send its link. The link alone opens the trace read-only. You invite by username the people who should comment or help manage access:

RoleWhat it allows
OwnerManages everything, administrators included
AdministratorAdds members, opens or closes comments
Can commentReads the trace and comments on places
Read onlyReads the trace and the comments

Everyone notes what they know about the places, under their own name and colour: the fountain turned off in winter, the hut where the support crew waits, the bus stop to get home. The group can also put camping spots or stages to the vote, one vote per person, and keep the list of shared gear, who brings what.

Your personal points and private zones stay yours, unless you choose to share them with the team. All your traces, created or joined, are in “My traces”.

A shared trace can also be duplicated: you get your own copy, same route and same radius, without the comments or members of the original, to add your zones and points. That is what the posts of this blog offer, at the bottom of each trace sheet.

The team’s comments on the places of a traceNotes stay on the place, visible to the whole team

13. Exporting to your watch#

The places shown export as GPX waypoints, sorted in route order, with the Garmin icon of their kind, their category and their kilometer. Your watch or GPS announces them on the way. A route built in OnTrace also exports as a track, with its altitude.

14. Building a route without a file#

No GPX yet? Place points on the map in the order of your route: OnTrace joins them along the paths and roads that really exist, never as the crow flies. It builds the network of OpenStreetMap ways around your points and works out the shortest way through it, snapping each point to the nearest way. Ways are kept for seven days per square, like places, to stay usable when the source is overloaded.

Water, huts and supplies near your points appear with each click, and one click on one of them adds it to the route. Distance and climb show as you go, and the altitude of the ground is added once the route is done.

The same tool goes further:

  • Repair the water: when a section goes past the chosen threshold (2 to 50 km) without a water point, OnTrace looks for the nearest source in a wider corridor and adds the detour to reach it, if it stays within the chosen budget. A detour that would lengthen another dry section is undone and explained.
  • Split into stages: each day ends near a hut, a cabin, a gîte, a campsite or a hotel, within the chosen distance window. Effort counts kilometers and climb (one more kilometer for every hundred meters of climb), to keep the hilliest days shorter.
  • Compare three variants: the shortest, the one that avoids roads open to cars the most, and the one repaired for water with the most careful threshold, each with its distance, climb and share of road and path.

That split into stages is what the trace sheets of this blog use. Here is the one of the Tour du Mont Blanc, worked out every day from the same data as the map:

15. For organizations#

Non-profit clubs and associations have the Asso offer, free. Organizers, agencies and professional bodies have the Pro offer. Both add an organization space with its members and dashboard, and tools made for an event:

  • a race plan: aid, first aid and marshal stations placed on the trace, at a kilometer worked out by the server, with printable sheets per team,
  • a safety file in PDF: figures, profile, rescue, tricky passages, shelters, water and zones,
  • an offline roadbook: a single file readable on a phone without signal,
  • a library of approved traces, with the history of a race’s editions to compare one year with another.

The Pro offer adds an embeddable map in the organization’s colours, on its own site and even under its own domain, importing its own places from a CSV or GPX file, and an API with webhooks to connect OnTrace to its tools.

16. Moderation and trust#

Public reports and comments are reviewed. Automatic rules set aside what looks like advertising, such as a link, or the same note pasted on several places, until someone looks at it. Each moderation decision is explained to the person concerned, who can appeal it, and anyone can report illegal content from a dedicated page.

17. What OnTrace does not do, and why#

  • Walking times and the water to carry are on hold. They depend too much on slope, how technical the path is and the weather to be estimated honestly.
  • The trail heatmap is waiting. It will only show a square from three different people on, leaving out the first and last 500 meters of each trace, and there first need to be enough shared traces for it to say anything.
  • No coverage outside France for now, because several sources, including weather warnings and avalanche bulletins, only cover mainland France.
  • No offline base maps. Base map providers do not allow bulk downloads without an agreement. The offline roadbook covers the basic need without signal.

18. Your data#

OnTrace shows no ads. Only page visits are counted, without cookies and without following you from one day to the next. Place photos, which come from third-party sites, only load with your consent, which you can withdraw at any time.

With an account, you download everything the site keeps about you, or delete it, in one click from your profile. Your original traces stay yours, and only the people you invite can comment on them.

19. Under the hood#

For the curious: OnTrace is a web app written in TypeScript with Next.js, a PostgreSQL database and the Leaflet map library. GPX files are read as a stream, without loading them into memory in one go. The calculations of distance, dry stretch, reliability, zone calendars and stages are pure code, covered by nearly 2,500 automated tests. The app can be used with the keyboard, with a skip link, visible focus rings and a list of places you move through with the arrow keys.

Frequent questions#

Do I need an account?#

Not to search: import your trace and read it. An account lets you save a trace, share it, comment, report the state of a place or draw a zone.

Is my trace public?#

No. An anonymous search is not kept. A saved trace is only visible to people who have its link, and only those you invite can comment on it.

Why is a place I know missing?#

It may be missing from OpenStreetMap or refuges.info: you can add it there, and it will appear in OnTrace at the next refresh of its area, seven days at most. It may also be outside the chosen radius, or of a kind you did not tick.

How much does it cost?#

Searching, sharing and planning as a team are free. The Asso offer is free for clubs and associations. The Pro offer is quoted after a demo.

Try it#

The simplest way is to try with your own trace: open the map, drop your GPX file and read your route in order. Planning a great route? The blog posts on the Tour du Mont Blanc, the GR20 and the Stevenson Trail show what a full sheet looks like. Organizing a race, a walking holiday or club outings? See the Pro offer and the Asso offer.


Data: © OpenStreetMap contributors (ODbL), refuges.info, Transitous, IGN, Open-Meteo. The film was made with Remotion, on a sample trace.

GR20 · Corse

GR20: water, huts and stages across Corsica

Crossing Corsica on the GR20, from Calenzana to Conca: where to find water, where to sleep, how to split the stages and reach the route by train.

· 4 min read

Your own trace, just as precisely.

Import a GPX file or draw your route: OnTrace places water, huts, supplies and camping zones, each at its kilometer.