KML to CSV

Extract data from a KML file and convert it to CSV.

About KML to CSV

Google Earth, Google My Maps and many GPS apps export places as KML, an XML format that spreadsheets cannot open. This tool reads every Placemark in the file and writes a CSV with its name, description and coordinates, plus any custom fields stored in ExtendedData, so a map of shops, routes or field observations becomes a table you can filter and share.

Paste the KML, name the output file and download the CSV. Parsing is done by your browser's XML parser, so location data is never uploaded.

How to use KML to CSV step by step

  1. Export or open the KML file, copy its content and paste it into the text area. Compressed .kmz files must be unzipped first.
  2. Type the name of the CSV file.
  3. Click "Convert and download CSV". One row is written per Placemark.

Input and output example

Input

<kml xmlns="http://www.opengis.net/kml/2.2"><Document>
  <Placemark><name>Office</name><description>HQ</description>
    <Point><coordinates>-3.7038,40.4168,0</coordinates></Point></Placemark>
  <Placemark><name>Warehouse</name>
    <Point><coordinates>2.1734,41.3851,0</coordinates></Point></Placemark>
</Document></kml>

Output

name,description,coordinates
Office,HQ,"-3.7038,40.4168,0"
Warehouse,,"2.1734,41.3851,0"

Why use our KML to CSV?

Common use cases

Limits and tips

Frequently asked questions

What is a KML file?

KML (Keyhole Markup Language) is an XML format created for Google Earth to describe geographic features: points, lines, polygons, names, descriptions and styles. A KMZ file is the same content compressed in a ZIP archive. Google Maps, Google Earth, QGIS and many GPS tools read and write it.

Why are latitude and longitude in one column?

KML stores coordinates as a single string in the order longitude,latitude,altitude. The tool keeps that string intact so nothing is lost for lines and polygons. For points, use Text to Columns in Excel with a comma separator to split it into three columns.

Can I convert a KMZ file?

Not directly. Rename the .kmz to .zip, extract it and open the doc.kml inside; paste that content into the tool. The images and icons bundled in the KMZ are not needed for the CSV.

What is the difference between KML and GeoJSON?

Both describe geographic features. KML is XML-based, includes styling and is native to Google Earth. GeoJSON is JSON-based, has no styling and is the standard for web maps such as Leaflet and Mapbox. This site can also convert GeoJSON to CSV and CSV to both formats.

Is the KML uploaded?

No. The file is parsed with the DOMParser in your browser and the CSV is created locally.

Related tools

Other free utilities you may find useful

Available languages