Data format

KML converter

A .kml file is Keyhole Markup Language: an XML format describing geographic features together with how they should look and how a camera should view them — placemarks, paths, polygons, styles, icons and overlays. It carries presentation, which is what separates it from GPX and GeoJSON.

Private for supported formats — processed in your browser

Convert supported files

Runs on your device

Drop KML files here

Batch files can each use a different output. Nothing uploads for local conversions.

Working inputs include camera RAW, browser-local audio/video, PDF, CBZ/CBR comics, office documents, ebooks, markup, 3D models, structured text, images, and archives.

Where KML comes from

KML came from Keyhole Inc., whose Earth Viewer became Google Earth after Google's 2004 acquisition. Google handed the specification to the Open Geospatial Consortium, which adopted it as an international standard in 2008. Its zipped form, KMZ, bundles the document with its icons and overlay images, which is how most KML is actually distributed.

How KML works

  • Placemark elements pair a geometry with a name, description and style reference.
  • Coordinates are comma-separated longitude,latitude,altitude triples — with the altitude commonly omitted, giving a third ordering convention to keep straight.
  • Style and StyleMap elements define icons, line colours and fills, referenced by id from placemarks.
  • LookAt and Camera describe a viewpoint, so a file can direct how it is displayed.
  • NetworkLink can pull in remote content, which makes an unvalidated KML file a fetch risk.

When to use KML

  • Displaying geographic data in Google Earth or Google Maps
  • Sharing an annotated map with styling preserved
  • Publishing overlays, boundaries or points of interest
  • Converting styled map data into a format a web mapping library can consume

Strengths and limitations

Strengths

  • Carries presentation, not just geometry — the only one of these three that does
  • An OGC standard rather than a vendor format
  • KMZ bundles icons and imagery into a single distributable file

Limitations

  • Verbose, and mixing styling with data makes documents large
  • NetworkLink and remote overlays make untrusted files a security consideration
  • A third coordinate ordering convention, inviting yet more conversion errors

Compatibility

Native to Google Earth and Google My Maps, and supported by QGIS, ArcGIS and GDAL. Web mapping libraries usually want GeoJSON instead. Novus Convert parses placemarks and geometry locally — without following NetworkLink references — and converts to GeoJSON and GPX.

Geometry, names and descriptions are preserved. Styling, icons and camera viewpoints have no equivalent in GeoJSON or GPX and are not carried across.