poka.sh

Docs

KML

Generated by scripts/gen-format-pages.py from docs/data/format-metadata/, FILE_FORMATS.csv and docs/formats-master.csv. Do not edit by hand: change the source, then run the script.

KML Preview.

At a glance

Original creator Keyhole, Inc.; later Google and the Open Geospatial Consortium
Purpose Geographic data for an earth browser or online map: placemarks with points, lines and polygons, and image overlays, in XML.
Extensions .kml
Poka parser poka-kml
Viewer poka-vector-viewer
Depth tier Parser with a shared viewer (see Depth tiers)
Breadth tier B3 Core (see Breadth tiers)

How much Poka reads

B3 Core. Only the main content type or types are decoded (for example geometry but not materials, layers or annotations, or only one version family). The list of gaps is substantial.

Confidence: high (the reviewer read the code and a test that proves the claim). Basis: Reviewed 2026-10-16: parsers/poka-kml/src/lib.rs (kml crate 0.8.7 with repairs for truncated files and self-closing tags; Point, LineString, LinearRing, Polygon with holes, MultiGeometry; GroundOverlay by LatLonBox and gx:LatLonQuad) and tests/samples.rs over 2 corpus .kml files (testKML.kml, ogc-conformance.kml). Draws geometry and overlays as a 2D map only; the code ignores everything else. Covers KML 2.2 as read by the kml crate.

What Poka does not read

  • Placemark names, descriptions and labels are not shown
  • Styles are ignored: line and fill colours, icons, line widths
  • Altitude and extrude are ignored (flat 2D lon/lat)
  • 3D models (COLLADA) are not drawn
  • NetworkLink, ScreenOverlay, PhotoOverlay and Tour elements are ignored
  • gx:Track and gx:MultiTrack paths are not drawn
  • Time spans and animation, regions, ExtendedData and Schema are ignored
  • Rotated or quad-placed overlay images are drawn as outlines
  • Overlay images in a plain .kml are drawn only from base64 data: URIs, otherwise as outlines
  • Folder and Document structure is flattened, with no layer tree or visibility
  • Capped at 32 MB and 256 levels of nesting

Background

Keyhole, Inc. developed KML for its Keyhole Earth Viewer. Google bought Keyhole in 2004 and the viewer became Google Earth. KML 2.2 was adopted as an Open Geospatial Consortium standard in 2008. Poka draws a 2D map: every Placemark geometry, and GroundOverlay images placed by their LatLonBox. 3D models are not drawn, and an image placed by a rotated box or a gx:LatLonQuad is drawn as its outline.

Versions

Version Identifier Poka Note
KML 2.2 (OGC) Partly read Placemark geometry and overlays; 3D models are not drawn.

Libraries

Libraries Poka uses or has assessed for this format, with the status, licence and language the registry records.

  • kml (used; MIT OR Apache-2.0; Rust)
  • quick-xml (used; MIT; Rust)
  • fastkml (candidate; LGPL-2.1; Python; https://github.com/cleder/fastkml) — Reads, writes and manipulates KML; uses lxml if present. Repo page shows LGPL-2.1 label but also an LGPL-3.0 badge, so version is slightly unclear.
  • libkml (candidate; licence unconfirmed; C++; https://github.com/libkml/libkml) — Reference implementation of OGC KML 2.2 for parsing and generating KML/KMZ; repo page did not name the licence; language from search summary.

Software that uses it

  • KML / KMZ (Google Earth)

Sources