# Loding kml from local drive

**URL:** https://community.cesium.com/t/loding-kml-from-local-drive/4495
**Category:** CesiumJS
**Created:** [August 14, 2016, 2:55pm UTC](https://community.cesium.com/t/loding-kml-from-local-drive/4495 "2016-08-14T14:55:16Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![ruediger.ebert](https://avatars.discourse-cdn.com/v4/letter/r/d6d6ee/32.png) [@ruediger.ebert](https://community.cesium.com/u/ruediger.ebert)
#### Post date: [August 14, 2016, 2:55pm UTC](https://community.cesium.com/t/loding-kml-from-local-drive/4495/1 "2016-08-14T14:55:16Z")

</div>

Is their a way to load a KmlDataSource from a local drive? In my app the kml files generated and updated on the client PC? I was not sucessful to laod the kml file into da datasource (Cesium.KmlDataSource(C:…).  
Probably a newbie mistake 😉

Thanks for any help…

---

<div class="post-metadata">

### Author: ![Terry\_Brown1](https://avatars.discourse-cdn.com/v4/letter/t/7993a0/32.png) [@Terry\_Brown1](https://community.cesium.com/u/Terry_Brown1)
#### Post date: [August 14, 2016, 6:59pm UTC](https://community.cesium.com/t/loding-kml-from-local-drive/4495/2 "2016-08-14T18:59:34Z")

</div>

It would probably be something like:

&nbsp;&nbsp;Cesium.KmlDataSource("file://C:/some/path/...");

(i.e. specify protocol and use forward slashes.)

But there are cases where you just can't use "file://", something to do  
with cross site scripting security etc. Then you have to run an HTTP  
server, but that's easy:

C:\Python27\python -m SimpleHTTPServer

will run a simple HTTP server in the folder you command prompt was at  
when you enter the above. Windows firewall may pop up, you can tell it  
it's ok for local machines.

Then you can browse to [http://127.0.0.1:8000/](http://127.0.0.1:8000/) to see the content of  
the folder your ran that from, click on you HTML file there, and links  
to local files should work. Note, now you'd leave the protocol off,  
i.e. don't use file, and it will default to http:// same as the  
page you just loaded.

Hope that helps.

Cheers -Terry
