Wednesday, 16 March 2016 10:47
Modified: Thursday, 18 October 2018 11:44
How to use Google Maps API Keys 4.0 out of 5 based on 8 votes.

how to use google maps api keys

As of June 22, 2016 Google made the following changes to the Google Maps APIs Standard Plan: No longer support keyless access (any request that doesn't include an API key) so you need to put the API keys to make the Google Maps work!

Google Maps has query limits per IP:

  • 2,500 free requests per day
  • 10 requests per second

Normally its enough for sites but if you have website on some shared hosting this limit is splited to all websites which use Google gocoding on the same IP.

In this situation Google Maps returns error OVER_QUERY_LIMIT and geocoding in search or generating Latitude and Longitude after posting new advert can't be done. Solution for this is to set Google Maps API Key in DJ-Classifieds options individual for your website.

What are and how to get Google Maps Server and Browser keys 

Server key 

What Google says about Server key:

Create and use a server key if your application runs on a server. Do not use this key outside of your server code. For example, do not embed it in a web page. To prevent quota theft, restrict your key so that requests are only allowed from your servers' source IP addresses.

Follow this steps to get Server Key

IMPORTANT: As recently Google changed the API of Google Maps on some accounts you may not see the option to create separate Server Key. In such a case, if you cannot find the option to generate it, use Browser Key in the Server Key field in DJ-Classifieds options.

Browser key

What Google says about Browser key:

Create and use a browser key if your application runs on a client, such as a web browser. To prevent your key from being used on unauthorized sites, only allow referrals from domains you administer.

Follow this steps to get Browser key

Once you have the keys generated you should enter them in Components -> DJ-Classifieds -> Options -> Global tab in Map & Locations Settings section

Ok, I put the keys but something is still not working

Check if you have enabled these libraries:

  • Google Maps Directions API
  • Google Maps Geocoding API
  • Google Maps Geolocation API
  • Google Maps JavaScript API
  • Google Places API Web Service


To do so:

  1. go to Google API Console
  2. create new or select existing project
  3. click Library in left sidebar and enable libraries listed above (just click on the library and enable it on details page google-maps-api-keys-enable-library)

Note: Two API keys (Browser & Server) can be added starting from version 3.4.6 of DJ-Classifieds. If you see only one field to update API key - update to most recent version of DJ-Classifieds!


Note: If you're sure you have put the API keys correctly and something still does not work (you see errors in the console), make sure that you have not overriden those files:

  • components/com_djclassifieds/views/item/tmpl/default_localization.php

and modules:

  • modules/mod_djclassifieds_maps/tmpl/cluster.php
  • modules/mod_djclassifieds_maps/tmpl/default.php
  • modules/mod_djclassifieds_search/tmpl/default.php

Questions? Let us know!


Related articles

User Rating:  (8)


Ultimate classified ads solution for Joomla.

Learn more