The python package simplekml was created to generate kml (or kmz). It was designed to alleviate the burden of having to study KML in order to achieve anything worthwhile with it. If you have a simple understanding of the structure of KML, then simplekml is easy to run with and create usable KML.

If you want get started right away you can download the latest version from PyPi and then head over to Getting Started for a quick example.

Simplekml is licensed under the GNU Lesser General Public License.


  • Download the latest version from PyPi.
  • KML Reference as published by Google for a good understanding of what KML is capable of.
  • Samples File (right-click > Save link as…) for example code with corresponding KML. This file is simply a network link. When examples and tutorials are updated the updates will reflect in the sample file (needs to be redownloaded if it was downloaded prior to 1.2.8).
  • Polycircles is a Python package that uses simplekml to create Polygonal circle approximation KMLs (because KML does not support circle geometry).

Table of Contents

Indices and tables