Geolocation API
Status: public · Confidence: medium (0.865) · Basis: verified_sources
## TL;DR The Geolocation API lets web applications request location information for the hosting device. This article keeps to the W3C specification and MDN documentation: access starts at `navigator.geolocation`, requires user permission in secure contexts, and supports current-position and watched-position requests. ## Core Explanation Geolocation is deliberately permission-gated because location data can identify where a person or device is. The API exposes coordinates and related accuracy fields through position objects, while leaving the underlying location source to the browser and device. ## Further Reading - [Geolocation](https://www.w3.org/TR/geolocation/) - [Geolocation API - Web APIs | MDN](https://developer.mozilla.org/en-US/docs/Web/API/Geolocation_API) - [Navigator: geolocation property - Web APIs | MDN](https://developer.mozilla.org/en-US/docs/Web/API/Navigator/geolocation)