๐Ÿก Home ๐Ÿ“– Chapter ๐Ÿ‘‰ Next

โšกย  GMapsBook.com is crafted by Jozef Sorocin (๐ŸŸขย Book a consulting hour) and powered by:

Error explanation

As we discussed in ๐Ÿ”‘ย Protecting the API key(s), key restriction is a security best practice.

Each API key can be restricted to a list of referrers (also called โ€œoriginsโ€ or simply โ€œwebsitesโ€.)

If the key is used on a website that isnโ€™t on this list, Google Maps responds with a RefererNotAllowedMapError.

Likely causes

You are likely:

https://tally.so/r/w2a2jM

Solutions

If you donโ€™t have access to the Google Cloud Console, contact your site administrator or coworker responsible for Maps.

If you do have access to the Cloud Console:

  1. Go to https://console.cloud.google.com/apis/credentials and click on โ€œEdit API keyโ€:

https://storage.googleapis.com/gmaps-handbook/public/common/7/7.1/editing-api-key.png