Categories

Featured templates

WordPress Troubleshooter. How tо fix “Google API key is invalid” error

Andre Flores May 22, 2015
Rating: 5.0. From 2 votes.
Please wait...

Hello! This tutorial shows how to fix “Google API key is invalid” error.

WordPress Troubleshooter. How ti fix “Google API key is invalid” error

You may receive the following error on your site:

This page was unable to display a Google Maps element. The provided Google API key is invalid or this site is not authorized to use it. Error Code: InvalidKeyOrUnauthorizedURLMapError

wordpress.how_to_fix_google_api_key_is_invalid_error_1

Let’s learn how to get rid of it.

  1. Access your WordPress admin panel and navigate to Appearance ->Editor tab.

  2. On the appeared screen locate the static-map.php file in the list on the right:

    wordpress.how_to_fix_google_api_key_is_invalid_error_2

  3. Click on the file title to open it for editing.

  4. On the appeared interface locate the following line of code:

<script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?key=AIzaSyASm3CwaK9qtcZEWYa-iQwHaGi3gcosAJc&sensor=false"></script>

Replace it with the following:

<script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?v=3.exp&sensor=false"></script>

wordpress.how_to_fix_google_api_key_is_invalid_error_3

Click the Update File” button in the lower part of the screen to save changes.

Open your site and refresh the page. You can see the error is no longer displayed.

This is the end of the tutorial, you have learnt how to fix “Google API key is invalid” error.

Feel free to check the detailed video tutorial below:

WordPress Troubleshooter. How ti fix “Google API key is invalid” error

Best Premium Wordpress Templates
This entry was posted in WordPress Tutorials and tagged api, error, google, map, WordPress. Bookmark the permalink.

Submit a ticket

If you are still unable to find a sufficient tutorial regarding your issue please use the following link to submit a request to our technical support team. We'll provide you with our help and assistance within next 24 hours: Submit a ticket

Live Chat
We help you to choose the right product.