Load and display KML files in Salesforce Maps

Importing existing maps data from other mapping software can be invaluable. Salesforce Maps allows to display KML files as a layer.

First, you’ll need to add the KML file to Salesforce Files to be able to access it through Salesforce Maps.

Upload the KML file into Salesforce

  1. Open the App Launcher and type in Files. Click on Files to open it
  2. Create a new library and name it SF Maps Files 
upload kml file on salesforce maps
  1. Open the SF Maps Files library and click Add Files
  2. Click Upload and find your KML file

Add KML to Salesforce Maps as a Boundary layer

  1. Click the App Launcher and type in Salesforce Maps and open it
  2. Click on the Layers tab on the top left
  3. Next to the ON THE MAP tab in the left sidebar, hover the three dots and click on Add Boundary
add kml file on salesforce maps
  1. On the Boundary card, click on Type and select KML
add kml file on salesforce maps
  1. In the selector, select your previously uploaded KML file
  2. Click Apply Changes to see if the file loads on the map without problem (If you get an error, see the next section below)
  3. If everything loads correctly, click Save
display kml file on salesforce maps
  1. Type in a Name and Description
  2. Click on the Folder tab and select where you’d like to store the map layer
  3. Click Save

The shapes or placemarks will show in the color that they originally were in the Software they came from (Google Earth or ArcGIS). You can’t change the color or any attribute of the boundary once is loaded into Salesforce Maps. But, you can change the color using Google Earth.

Can’t display KML files in Salesforce Maps?

If you hit any of the limitations you’ll get a “Boundary Error: Unable to retrieve or parse the KML document” error message in the bottom right corner of Salesforce Maps.

It might be one of these reasons:

Was this article helpful?
YesNo