Geolocation error: User denied geolocation prompt

I’m putting this here because I ran into a confounding issue that it took me a long time to find a solution for, and I’m hoping to solve the issue for others in the same situation.

You’re using Firefox and OpenStreetMap on a Mac and you’re clicking on the “Show My Location” icon in the toolbar and you’re seeing the error “Geolocation error: User denied geolocation prompt”:

OpenStreetMap screen shot showing geolocaiton error dialog

You’re seeing this despite having granted Firefox permission to use your location for

Firefox permissions dialog for

You are confounded. You search for answers, and all you find are references to geolocation and https, but you’re already accessing via https, so that’s not the issue.

The issue might lie with your macOS Location Settings:

Screen shot of macOS Location Settings

Open System Preferences > Security & Privacy > Location Services and make sure the settings is checked (you might need to click on the padlock in the bottom-left and enter your system password to be able to make this change).

Once you do this, you should find that the “Show My Location” process works in OpenStreetMap as expected:

Screen shot showing OpenStreetMap Show My Location working in Firefox


Paolo Capaldo's picture
Paolo Capaldo on October 14, 2019 - 11:08 Permalink

yes it works! very useful
thank you very much

paul's picture
paul on January 7, 2020 - 13:39 Permalink

Wow, could have been stuck on this for a very long time... Thanks, your post really helped.

Brian's picture
Brian on February 20, 2020 - 12:16 Permalink

Thank you so much for this! I was totally stuck trying to figure out why this was broken in FF.

Wedge's picture
Wedge on January 22, 2021 - 08:36 Permalink

May you look fantastic in hats for the rest of your days.

P's picture
P on October 23, 2023 - 06:18 Permalink

May a panda be born for every developer you've helped with this issue!