 <p>Access to a KML file can not be done locally each service based on google it must be made by means of a publicly accessible server on the Internet. it tries to place your file on a server accessible from the internet (there are also free services)</p> <p>this form google maps developer </p> <blockquote> <p>Your file is hosted publicly on the internet. This is a requirement for all applications loading KML into a KMLLayer. Google's servers need to be able to find and retrieve the content in order to display it on the map - this also means that the file can't be on a password-protected page.</p> </blockquote> <p><a href="https://developers.google.com/maps/tutorials/kml/#your_kml_file" rel="nofollow">https://developers.google.com/maps/tutorials/kml/#your_kml_file</a></p>