KML to GPX Converter
Converts the placemarks of a KML file to GPX waypoints and routes with GDAL's ogr2ogr.
Upload a .kml file. A GPX file holds only waypoints, routes and tracks, so the worker sorts the KML placemarks by geometry type: points become waypoints, lines become routes. Heights are written as <ele>; polygons cannot be stored and are listed in the report.
Drag a file here to convert, or select file
Accepted: .kml · max. 50 MB
What the converter does
- GPX knows only waypoints, routes and tracks. Points become waypoints, lines become routes, multilines become tracks.
- Polygons cannot be stored in GPX and are not exported; the report names the layer and the number of polygons.
- GPX requires longitude/latitude: the worker reprojects to WGS84 (-t_srs EPSG:4326) if every layer has a coordinate system. If one does not, the coordinates are written unchanged and the report warns about it.
- Attributes that are not standard GPX fields are written as GPX extensions (<ogr:name> elements, option GPX_USE_EXTENSIONS=YES).
- KML folders do not survive as such: all points of all folders become waypoints, all lines become routes.
- Heights from the KML are written as <ele>.
- Because a GPX file can only be written in one go, the worker first sorts the placemarks by geometry type into a temporary GeoPackage (gpx_staging.gpkg) and writes the GPX from there.
- The report below the upload shows layers and features read and written, skipped layers with the reason, GDAL's warnings and the exact commands.
GDAL command the worker runs
For a KML with one folder Wege containing lines with heights. The worker runs the first command once per folder and geometry type (POINT with -nlt POINT25D for points; without 25D if there are no heights) and then writes all of them into the GPX in one call.
Tested with
| Test file | Result |
|---|---|
| KML with 1 placemark in the document and 2 folders (2 points with ExtendedData, 1 line with heights 45/46/44 m) | GPX with 3 waypoints and 1 route; 4 of 4; route points with <ele> 45, 46, 44; ExtendedData as extensions (ogr:linien, ogr:barrierefreiheit_status) |
Tested on 24 Sep 2026 with the worker code of this site and GDAL 3.10.3 (conda-forge build on Windows). The worker image runs the Debian build of the same GDAL version; the live worker was not part of these tests.
Limits
- Upload limit: 50 MB per file.
- Polygons are not exported (GPX has no areas).
- Only .kml, not .kmz.
- Each GDAL step may run for up to 240 seconds; a longer run is stopped with an error message.
Frequently Asked Questions
What happens to polygons?
GPX cannot store areas, so polygons are not exported. The report names the folder and the geometry types that were left out; they are not dropped silently.
What happens to my file?
Your browser uploads it directly to the GDAL worker on Fly.io (region Frankfurt). The worker converts it in a temporary folder and deletes the folder after sending the result, or immediately if the conversion fails. Files are not stored permanently.