HTML DOM Geolocation coords.altitude Property Last Updated : 23 Nov, 2021 Comments Improve Suggest changes Like Article Like Report In this article, we will discuss the Geolocation altitude property. Geolocation in HTML is used to get the geographical position of a user. The getCurrentPosition() method, in this geolocation, returns an object on success. coords.altitude: This property will return the altitude in meters above the sea level. Syntax: coords.altitude Example: The following HTML code will return the altitude. HTML <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width,initial-scale=1"> </head> <body> <h2 style="color:green">GeeksforGeeks</h2> <p><b> Displaying Altitude</b></p> <button onclick="getlocation()"> Click Me </button> <p id="paraID"></p> <script> var variable1 = document.getElementById("paraID"); function getlocation() { navigator.geolocation.getCurrentPosition(showLoc); } function showLoc(pos) { variable1.innerHTML = "Altitude: " + pos.coords.altitude; } </script> </body> </html> Output: Supported Browsers: Google Chrome 5.0 Internet Explorer 9.0 Firefox 3.5 Opera 16.0 Safari 5.0 Comment More infoAdvertise with us Next Article HTML DOM Geolocation coords.speed Property O ojaswilavu8128 Follow Improve Article Tags : HTML HTML-DOM HTML-Property Similar Reads HTML DOM Geolocation coords.altitudeAccuracy Property In this article, we will discuss the Geolocation altitudeAccuracy property. Geolocation in HTML is used to get the geographical position of a user. The getCurrentPosition() method, in this geolocation, returns an object on success. coords.altitudeAccuracy: This property will return the accuracy posi 1 min read HTML DOM Geolocation coords.accuracy Property In this article, we will discuss the Geolocation accuracy property. Geolocation in HTML is used to get the geographical position of a user. The getCurrentPosition() method in this geolocation returns an object on success. HTML Geolocation coords.accuracy Property: This property will return the accur 1 min read HTML DOM Geolocation coordinates Property The DOM Geolocation coordinates Property in HTML is used to return the position and altitude of the device on Earth. The returned Coordinates object could be used for various purposes including navigation and tracking the position of the device. Property Values: ValuesDescriptioncoordinates.latitude 2 min read HTML DOM Geolocation coords.speed Property In this article, we will discuss the Geolocation speed property. Geolocation in HTML is used to get the geographical position of a user. The coords.speed property is used to return the speed in the location in meters per second (mps). Syntax: coords.speed Example: The following HTML code will return 1 min read HTML DOM Geolocation coords.heading Property In this article, we will discuss about the Geolocation coords.heading property. Geolocation in HTML is used to get the geographical position of a user. The getCurrentPosition() method in this geolocation returns an object on success. The Geolocation coords.heading property is used return the clock w 1 min read HTML DOM Geolocation coords.latitude Property In this article, we will discuss the Geolocation latitude property. Geolocation in HTML is used to get the geographical position of a user. The getCurrentPosition() method, in this geolocation, returns an object on success. coords.latitude: This property will return the latitude as a decimal number. 1 min read Like