.KML

KML File

Keyhole Markup Language
Ask a question
QUICK ANSWER

A KML file stores map data - pins, routes, polygons, image overlays - in plain XML format. The easiest way to open one is Google Earth (free desktop app or earth.google.com in a browser) or Google My Maps. For GPS devices like Garmin, convert it to GPX with GPSBabel.

Developer: Keyhole, Inc. (acquired by Google 2004); standard now maintained by the Open Geospatial Consortium (OGC) Category: GIS Files Open standard MIME: application/vnd.google-earth.kml+xml
OPENS ON Windows macOS Linux Android iOS Web
Related: .GPX · .GML · .SHP · .RTMAP

On this page

19k+ extensions indexed
Last reviewed Jul 25, 2026

Not sure what your file is?

Drop any file into our identifier - we read just the first bytes to name the format.

Identify a file

What is the KML file format?

A .kml file contains geographic data saved in an XML-based format. KML files can store information about:

  • Points,
  • Lines and paths,
  • Polygons,
  • Images and overlays,
  • 3D models,
  • Text descriptions and HTML pop-ups.

Data stored in .kml files is used for marking and describing geographical locations, adding camera viewpoints, or layering overlay textures on maps. Each location is described by its coordinates (latitude and longitude) following the WGS84 standard, and optionally with a third coordinate - altitude above mean sea level, which defaults to 0. A camera view or time span can also be defined. .kml shares structural similarities with the GML format.

.kml files are commonly distributed as .kmz archives - ZIP-compressed packages that bundle the .kml document together with any referenced images or models. The name Keyhole Markup Language derives from Keyhole, Inc., the company that originally developed the format. Google acquired Keyhole in 2004 and integrated the technology into Google Earth, enabling both offline and online viewing and editing of .kml data. In 2008, the Open Geospatial Consortium (OGC) standardized KML 2.2 as an open format for geo-browsers.

Security & safety

RISK: LOW

KML is plain XML with no executable code, so the file itself is safe to open. Two things to be aware of: a <NetworkLink> element can make a KML automatically fetch remote content from a URL when opened (a privacy/tracking vector and, in theory, a way to pull in unexpected data) - be cautious with KML from untrusted sources. Also, map data can be privacy-sensitive: a shared route or set of pins can reveal a home address or regular movements. KMZ files are ZIP archives, so the usual advice about only unzipping trusted archives applies.

Format details

in a nutshell
FULL NAMEKeyhole Markup Language
DEVELOPERKeyhole, Inc. (acquired by Google 2004); standard now maintained by the Open Geospatial Consortium (OGC)since 2004 (Google acquired Keyhole); KML 2.2 adopted as an OGC standard in 2008
CATEGORYGIS Files
MIME TYPEapplication/vnd.google-earth.kml+xml
TYPEXML text (geographic data)
STANDARDOpen · royalty-free

Programs that open KML files

Windows4 apps
Global Mapper Paid Professional GIS app; File > Open to load KML and convert between many geospatial formats.
Google Earth Pro (desktop) Free File > Open and select the .kml/.kmz - it loads onto the globe. Free for everyone since 2015.
QGIS Open-source Layer > Add Vector Layer, pick the .kml to view it as GIS data and convert it to other formats.
Notepad / VS Code Open-source Open the .kml as text to read or edit the raw XML (KMZ must be unzipped first).
macOS2 apps
Google Earth Pro (desktop) Free File > Open to load the .kml/.kmz onto the globe.
QGIS Open-source Add the .kml as a vector layer to view and convert the map data (Apple silicon and Intel builds).
Linux2 apps
GPSBabel Open-source Command-line/GUI tool to read KML and convert it to GPX and dozens of GPS formats.
QGIS Open-source Add the .kml as a vector layer; GDAL/OGR underneath handles KML/KMZ.
Android1 app
Google Earth (app) Free Open the KML/KMZ via the Projects menu to view it on the mobile globe.
iOS1 app
Google Earth (app) Free Import the KML/KMZ through the Projects menu to view it on iPhone/iPad.
Web2 apps
Google Earth (web) Free Open earth.google.com, use the menu > Projects > Open > Import KML file to view it in the browser. No install.
Google My Maps Free Create a new map > Import and upload the .kml/.kmz to view and edit pins/lines/areas in the browser.

Technical details

deep spec
MIME typeapplication/vnd.google-earth.kml+xml
File encodingPlain UTF-8 XML text; no binary header or magic bytes
XML root element`<kml>` with namespace `xmlns="http://www.opengis.net/kml/2.2"`
Coordinate systemWGS84 (EPSG:4326) - longitude, latitude, optional altitude in metres
Coordinate orderLongitude before latitude (opposite to the ISO 6709 / GeoJSON convention)
Altitude modes`clampToGround`, `relativeToGround`, `absolute`
Geometry typesPoint, LineString, LinearRing, Polygon, MultiGeometry, Model
Styling systemInline `<Style>` and shared `<StyleMap>` elements control icon, color, line width, and label
Time elements`<TimeStamp>` for a single instant; `<TimeSpan>` for an interval - enables temporal animation in geo-browsers
Overlay typesGroundOverlay (image on terrain), ScreenOverlay (HUD graphic), PhotoOverlay (360° photo)
Network links`<NetworkLink>` fetches remote KML/KMZ data dynamically, enabling live-updated map layers
3D model referencesReferences external COLLADA (`.dae`) files via `<Model>` element for 3D objects placed on terrain
Compressed variant`.kmz` - a ZIP archive bundling the `.kml` file with referenced images and models
Standardizing bodyOpen Geospatial Consortium (OGC); KML 2.2 standardized April 2008 (document OGC 07-147r2)
Balloon pop-ups`<description>` field accepts plain text or HTML, displayed as an info balloon on feature click
Released2004 (Google acquired Keyhole); KML 2.2 adopted as an OGC standard in 2008
Open standardYes · royalty-free
Specificationwww.ogc.org

KML conversions

Community Q&A

asked by users
Ask a quick question
Get help from people who work with KML files. Be specific - include your system and software version.
No account needed · answers usually within a day

No questions yet - be the first to ask about KML files.

Frequently asked questions

How do I open a KML file?
Import it into Google Earth - the free desktop Google Earth Pro (File > Open) or the web version at earth.google.com (Projects > Import KML file). You can also upload it to Google My Maps, open it in QGIS, or read the raw XML in any text editor.
What is the difference between KML and KMZ?
KML is the plain XML map file; KMZ is the same data ZIP-compressed, often with the referenced images/icons bundled inside. KMZ is smaller and more common for sharing. Any tool that opens one opens the other; you can unzip a KMZ to get the doc.kml.
How do I convert KML to GPX?
Use the free GPSBabel desktop tool or the GPS Visualizer website, or QGIS - load the KML and export to GPX. GPX is what Garmin devices and Strava/Komoot expect for routes and waypoints.
Can I open a KML file in Google Maps?
Not in the regular Google Maps app directly. Use Google My Maps (mymaps.google.com): create a map, choose Import, and upload the .kml/.kmz to view and edit it in the browser.
Can I edit a KML file?
Yes - it's plain XML, so a text editor works for small edits, but it's easy to break the syntax. For safe editing use Google Earth, Google My Maps or QGIS, which let you move pins and reshape lines/areas visually.
How do I open a KML on my phone?
Install the Google Earth app (Android/iOS) and import the file via the Projects menu, or open it in Google My Maps in a mobile browser. Both show the pins, lines and areas on a map.

References

1OGC - KML standardwww.ogc.org
2Google - KML documentation & referencedevelopers.google.com

Keep exploring

across the database

Top extensions this week

1.AQQAQQ Instant Messenger File
2.CRDOWNLOADChrome Partial Download File
3.PARTPartial Download File
4.BINCD/DVD Disc Image (BIN/CUE)
5.RPMSGRestricted Permission Message
6.MDMarkdown Document
7.NOMEDIAAndroid No-Media Marker File
8.PRO6XProPresenter 6 Bundle File
9.PRDXSoftMaker Presentations Document
10.EXEWindows Executable (Portable Executable)

Related extensions

.GPXGPS Exchange Format
.GMLGeography Markup Language
.SHPEsri Shapefile (geospatial vector data)
.RTMAPCompeGPS / TwoNav Tiled Raster Map
.KMZKeyhole Markup Language Zipped (Google Earth)
.GDBGarmin MapSource GPS Database

Free file tools

An in-browser file identifier and image converter - everything runs on your device.

Open the toolbox

Browse file extensions A-Z