GPX to GeoJSON Converter

Turn GPS tracks into GeoJSON for web maps and data pipelines

Ad placeholder (leaderboard)

GPX is the format GPS devices export; GeoJSON (RFC 7946) is the lingua franca of web mapping libraries like Leaflet and Mapbox GL and desktop GIS like QGIS. This free converter turns one into the other in your browser, so you can put a recorded route on a web map or into a data pipeline without uploading your private location history.

How it works

The converter parses the GPX and emits a GeoJSON FeatureCollection:

  1. DOMParser reads the GPX and finds every wpt, trk and rte.
  2. Each waypoint becomes a Feature with Point geometry; its name/desc go into properties.
  3. Each track segment (trkseg) and route is flattened into an ordered coordinate array and emitted as a LineString feature.
  4. Coordinates are written as [lon, lat, ele]longitude first, the order RFC 7946 mandates — with elevation added as a third value when present.

The result is a single FeatureCollection, valid GeoJSON ready for any mapping tool.

Tips and example

A GPX waypoint <wpt lat="48.2082" lon="16.3738"/> becomes:

{ "type": "Feature", "geometry": { "type": "Point", "coordinates": [16.3738, 48.2082] }, "properties": {} }

Note the reversed order: GeoJSON is [lon, lat], the opposite of how you usually say a coordinate aloud. A common mistake is feeding [lat, lon] into a map and seeing points land in the wrong hemisphere — this tool always writes longitude first.

Everything runs locally; your GPS data is never uploaded.

Ad placeholder (rectangle)