This happens because you may have added IP/ HTTP referrer restrictions for your public access tokens. You'll see this error if requests do not originate from the IP/ referrer you approved. 

To verify the configuration of your access token:

  1. Login to the LocationIQ dashboard
  2. Please navigate to the 'API Access Tokens' tab
  3. Select the token of your choice and click 'View'

You'll find authorized HTTP referrers and IP addresses here. If you want to update this:

  • Click 'Update'
  • Modify approved referrers/ IP addresses
  • Click 'Update'

You can define a list of URLs authorised to call our APIs or Maps with an access token. If not specified or empty, the API will default to any URL. URLs can be targeted by matching a prefix or a suffix using the * character. For multiple HTTP referrers, specify one pattern per line.

A few examples:

"* will restrict access to all referrers starting with

* will restrict access to all referrers ending with

If you want to allow access for the full domain, you can use **