If you are paying for the Google API key, then skip this step. Conversely, in case you want to display the map on your site for free, you can learn more to add Google Map to WordPress and add Google Map to Joomla 4 articles.
- Chrome: Ctrl + Shift + J (Windows and Linus) or CMD + Opt + J (Mac OS).
- Safari: CMD + Opt + C.
- Firefox: Ctrl + Shift + K (Windows and Linus) or CMD + Opt + K (Mac OS).
- Google Maps API Error: MissingKeyMapError.
- Google Maps API Error: RefererNotAllowedMapError.
- Google Maps API Error: ApiNotActivatedMapError.
- Google Maps API Error: InvalidKeyMapError.
Each type will have a different solution, so after knowing the error of your site, we will move on to the following detailed methods.
This error occurs when you don’t use any API key. Thus, you need to create and get a Google Maps API key.
Let’s follow the steps:
- Access Google Maps Platform -> Click on the Get Started.
- Fill out some information -> Create a project.
- Add payment method -> Select the products -> Choose Maps.
- Click Enable -> Answer a short survey.
- A popup with generated API key will be showcased -> Copy it -> click Done.
- Open Geolocation API -> Press Enable.
- Choose Credentials on the menu -> Click Maps API Key.
- Select HTTP Referrers in the Application restrictions section.
- In the Website restrictions section, utilize Add an item to add two entries, including yourname.com/* and *.yourname.com/* (remember to change yourname.com into your domain).
- Click the save button -> Use the API key for the Google Maps of your site.
The error is the most common of 4 Google Maps API Error types. There is something wrong with the Application restrictions. So, you need to check it to ensure everything is exact.
In order to tackle this error, simply implement the following steps:
- Open Credentials Console.
- Find the API key’s name -> Click to edit the setting.
- In the Application restrictions section, check that you have already chosen HTTP referrers (websites) as well as added both of the entries: yourname.com/* and *.yourname.com/* (make sure to replace yourname.com with your domain).
- Click Save and wait a few minutes -> Refresh the site to check the result.
This error happens because you may not enable the API you are using. Thus, all you need to do is enable it.
If you want to solve this error, let’s start:
- Access Library Console.
- Click on View All to see all APIs -> Find the API you are utilizing -> Press it.
- Click on the Enable button at the top of the screen.
This error means that the API key you are utilizing is wrong. So, you simply copy the API key you created before and paste it to your site.
To solve this trouble, you just need:
- Go to Credentials Console.
- Copy the API Key.
- Open your back-end site and paste the key -> Save.
- Wait a few minutes -> Refresh the site and see the result.
- Wait at least five minutes for all changes to take effect.
- Clear the cache.
- Check the console as well as each step of the solution again to make sure you follow the true process.
Last but not least, we are offering both free WordPress Themes and Joomla 4 Templates. All of them are responsive and SEO-friendly, so if you want to get a great one, let’s have a look at the collection. Thanks for your reading and hope you enjoy the blog.
- Web App Vs Progressive Web App: Why Are They Different - June 30, 2022
- 3CX Vs Help Scout: What are the differences - June 20, 2022
- List Of 7 Best WordPress Video Conference Plugins 2022 - June 16, 2022