How to convert a CAD site file to KML/KMZ with QGIS

Want to use your CAD file in pvDesign? Here, you will learn how to convert it to the right format!

In case you are more familiar with CAD files when it comes to site definition, you will need to convert it to KML or KMZ format. This guide aims to explain how to successfully convert the CAD file (.DWG) by using QGIS.

If you prefer to use AutoCAD Map 3D, you can read this article

Open QGIS and follow these steps:

  • First, you'll need the KML tools plugin

  • Now you have to import your DWG file to QGIS with the Import layers from DWG/DXF tool (inside Project > Import/Export > Import layers from DWG/DXF).

If the file is saved as a 2018 version, QGIS will not be able to import it. In this case, you can save it again as a 2013 version.

  • While importing, don't forget to set the coordinate reference system (CRS) by checking the EPSG of your file. If you don't know it, you can try to find it using this website:
  • The next step is to manually transform the areas that are not in the right format, into polygons with the "line to polygon" tool and the other geometry tools

You can find more useful tools to help you modify your file with QGIS in these other tutorials:

  • When it's done you can export each area to KMZ

Tip: If the export to KML failed you can try the dissolve tool on your layer before exporting.

  • Then you need to open all your KMZ files in Google Earth and set the correct names, add the placemarks, and save every area in one KML file.

After all these steps, you are ready to export your file to pvDesign and start designing your PV plant.

For any other questions or more information regarding this topic, you can contact us at: