Click on location, and get its GPS coords?


Unless I missed it, doesn’t let me just click on any location, and get its GPS lat/lon coordinates.

Is there an OSM-site that does this? Even better: After clicking, the coords should be copied to the clipboard, ready to be pasted elsewhere.

Thank you.

The rendered maps are not provided for that sort of use.

However, click share on the the right hand side (arrow coming out of box) and enable set marker.

The rendered maps are provided mainly as an aid to contributing to the maps.

Note these are approximate WGS 84 positions, not specifically GPS ones.

Thanks. Ideally, I’m looking for something more point and click.

The Javascript library that OpenStreetMap uses is Leaflet. There’s lots of information at , including tutorials and documentation. There are also lots of plugins are available for that .

Here is a simple DIY example. Copy and paste the code into a text file and name it pointer.html for example. Open it with your web browser, left-click somewhere and the coordinates are saved to your clipboard

<!DOCTYPE html>


  <meta charset='utf-8' />
  <meta name="viewport" content="width=device-width, height=device-height, user-scalable=no"> 
  <link rel="stylesheet" href="" />
  <script src=""></script>


#mapDiv {
	position: absolute;


	<div  id="mapDiv" ></div>


function onMapClick(e) {
    var lat  =;
    var lon  = e.latlng.lng.toFixed(5);
    var gps = "";
    if (lat>0) gps+='N'; else gps+='S';
    if (10>Math.abs(lat))  gps += "0";
    gps += Math.abs(lat).toFixed(5)+" ";
    if (lon>0) gps+='E'; else gps+='W';
    if (10>Math.abs(lon))  gps += "0";
    if (100>Math.abs(lon)) gps += "0";
    gps += Math.abs(lon).toFixed(5);
    var textArea = document.createElement("textarea"); = 'fixed'; = 0; = 0; = '2em'; = '2em'; = 0; = 'none'; = 'none'; = 'none'; = 'transparent';
    textArea.value = gps;
    try {
      var successful = document.execCommand('copy');
      var msg = successful ? 'Successfully' : 'Unsuccessfully';
      console.log(msg + ' copied ' + gps + ' to clipboard ');
    } catch (err) {
      console.log('Oops, unable to copy');

var osmUrl='https://{s}{z}/{x}/{y}.png';
var osm = new L.TileLayer(osmUrl, {minZoom:2, maxZoom:19});		

var googleStreets = new L.tileLayer('https://{s}{x}&y={y}&z={z}',{minZoom:1, maxZoom:19, subdomains:['mt0','mt1','mt2','mt3']});

var googleSat = new L.tileLayer('https://{s}{x}&y={y}&z={z}',{minZoom:1, maxZoom: 21,subdomains:['mt0','mt1','mt2','mt3']});

var map = new L.Map('mapDiv', { doubleClickZoom:false, zoomControl:false, maxBounds:([[90,-270],[-90,270]]) });

L.control.layers({"OSM (Mapnik)": osm, "Google Street": googleStreets, "Google Earth": googleSat}).addTo(map);

var map_set = "osm";

map.on('click', onMapClick);