{"id":17877,"date":"2019-02-18T16:46:34","date_gmt":"2019-02-18T10:46:34","guid":{"rendered":"http:\/\/wp\/?page_id=17877"},"modified":"2020-11-15T15:01:04","modified_gmt":"2020-11-15T15:01:04","slug":"google-maps-keys","status":"publish","type":"page","link":"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/google-maps-keys\/","title":{"rendered":"Google API keys"},"content":{"rendered":"<div class=\"w2gm-docs w2gm-docs-side\">\n<h2 id=\"google_maps_keys\">Google API keys<\/h2>\n<p><strong>Since 2018 Google Maps is no longer free.<\/strong> You must enable billing with a credit card and have a valid API key for all of your projects <a href=\"https:\/\/developers.google.com\/maps\/billing\/understanding-cost-of-use\" rel=\"noopener noreferrer\" target=\"_blank\">https:\/\/developers.google.com\/maps\/billing\/understanding-cost-of-use<\/a>. This allows to get free usage of near 28K maps services requests monthly.<\/p>\n<p><strong>Google requires mandatory Maps API keys<\/strong> for maps created on new and existing websites\/domains. Otherwise it may cause problems with Google Maps, Geocoding, addition\/edition listings locations, autocomplete on addresses fields, search by radius.<\/p>\n<h4>Create browser API key<\/h4>\n<p><a href=\"https:\/\/console.developers.google.com\/flows\/enableapi?apiid=maps_backend,geocoding_backend,directions_backend,static_maps_backend,places_backend&keyType=CLIENT_SIDE&reusekey=true\" target=\"_blank\" rel=\"noopener noreferrer\">Create browser API key<\/a> in new project or in existing one.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"451\" height=\"234\" src=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-content\/uploads\/Create_project2.png\" alt=\"\" class=\"alignnone size-full wp-image-18355\" srcset=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-content\/uploads\/Create_project2.png 451w, https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-content\/uploads\/Create_project2-300x156.png 300w\" sizes=\"auto, (max-width: 451px) 100vw, 451px\" \/><\/p>\n<p>Step 2<br \/>\n<img decoding=\"async\" src=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-content\/uploads\/api_key_step2.png\" alt=\"\" class=\"alignnone size-full wp-image-23733\" \/><\/p>\n<p>The next screen allows you set to a name for the browser key, and restrict the usage of the browser key to the provided referrers. If you leave the referrer field empty, then it\u2019s possible for other users to use your key on their domains.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-content\/uploads\/api_key_browser.png\" alt=\"\" class=\"alignnone size-full wp-image-23736\" \/><\/p>\n<p>Set the referrer to <strong>*.yourdomain.com\/*<\/strong> to cover all pages on your site.<\/p>\n<h4>Create server API key<\/h4>\n<p><a href=\"https:\/\/console.developers.google.com\/flows\/enableapi?apiid=geocoding_backend&keyType=SERVER_SIDE&reusekey=true\" target=\"_blank\" rel=\"noopener noreferrer\">Create server API key<\/a> in new project or in existing one. Select the same project you used when you created the browser key and click 'Continue'.<\/p>\n<p><i class=\"fa fa-exclamation-triangle\"><\/i>To test server API key you can visit debug page and check geolocation response. Debug page is placed on your site by similar URL <strong>http:\/\/www.yoursite.com\/wp-admin\/admin.php?page=w2gm_debug<\/strong><\/p>\n<p>On the next screen set the referrer to the IP address of your server (this is optinal) to restrict the usage of the key. <a href=\"https:\/\/www.site24x7.com\/find-ip-address-of-web-site.html\" target=\"_blank\" rel=\"noopener noreferrer\">Here<\/a> you may find IP address of your site.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-content\/uploads\/api_key_server.png\" alt=\"\" class=\"alignnone size-full wp-image-23743\" \/><\/p>\n<p>Enter both keys in appropriate settings on the <a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/maps-addresses\/\">Maps & Addresses settings tab<\/a> of the plugin settings page.<\/p>\n<p>Take special attention to \"Accept requests from these HTTP referrers (web sites)\" (for browser key) and \"Accept requests from these server IP addresses\" (for server key) fields. If they will be wrongly filled in - it may cause problems with Google Maps and their functionality. You can try to leave them blank.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-content\/uploads\/api_key_dashboard.png\" alt=\"\" class=\"alignnone size-full wp-image-23748\" \/><\/p>\n<h4>When you are using existing project<\/h4>\n<p>You have to enable following APIs in the console: Google Maps JavaScript API, Google Static Maps API, Google Places API Web Service, Google Maps Geocoding API and Google Maps Directions API.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-content\/uploads\/api_key_apis.png\" alt=\"\" class=\"alignnone size-full wp-image-23735\" \/><\/p>\n<p>Click \"VIEW ALL\" link<br \/>\n<img decoding=\"async\" src=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-content\/uploads\/api_keys_apis2.png\" alt=\"\" class=\"alignnone size-full wp-image-23739\" \/><\/p>\n<p><i class=\"fa fa-exclamation-triangle\"><\/i> Sometimes it takes some time for keys activation. Also you could try to speed up the process (as some users did) in the following way: disable, delete, re-enable and re-create all your APIs and keys (or, at least, the ones that give you problems), and see if this fixes the issue for you. If you prefer, you could try with API keys from different account instead, but both keys from one project.\n<\/div>\n<div class=\"w2gm-theme-sticky\">\r\n<h4 class=\"w2gm-table-of-contents-heading\">Table of Contents<\/h4>\r\n<ul class=\"w2gm-table-of-contents\">\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/\">Installation<\/a>\r\n<ul>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/demo-content\/\">Demo data import<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/update\/\">Plugin update<\/a><\/li>\r\n<\/ul>\r\n<\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps-management\/\">Maps management<\/a>\r\n<ul>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps-management\/settings\/\">Map settings<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps-management\/ajax-loading\/\">Map AJAX loading<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps-management\/starting-point\/\">Map starting point and radius<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps-management\/controls\/\">Map controls<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps-management\/listings-sidebar\/\">Listings sidebar<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps-management\/search\/\">Search options<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps-management\/markers\/\">Markers to display<\/a><\/li>\r\n<\/ul>\r\n<\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps-listings\/\">Listings management<\/a>\r\n<ul>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps-categories\/\">Maps categories<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps-locations\/\">Maps locations<\/a><\/li>\r\n<\/ul>\r\n<\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/\">Maps settings<\/a>\r\n<ul>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/frontend-submission\/\">Frontend submission<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/claim\/\">Claim Functionality<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/listings\/\">Listings settings<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/listings-logos-images\/\">Listings logos & images<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/ratings\/\">Ratings settings<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/search\/\">Search settings<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/maps-addresses\/\">Maps & Addresses<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/email-notifications\/\">Email notifications<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/advanced\/\">Advanced settings<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/settings\/customization\/\">Customization<\/a><\/li>\r\n<\/ul>\r\n<\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/content-fields\/\">Content fields<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/search\/\">Search form<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/sorting-of-listings\/\">Sorting of listings<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/maps\/\">Maps & Markers Icons<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/google-maps-keys\/\">Google API keys<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/frontend\/\">Frontend submission & dashboard<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/widgets\/\">Widgets<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/customization\/\">Customization styles & templates<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/change-texts\/\">How to modify texts<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/translation\/\">Translation<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/import\/\">CSV Import<\/a><\/li>\r\n\t<li><a href=\"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/documentation\/troubleshooting\/\">Troubleshooting<\/a><\/li>\r\n<\/ul>\r\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Google API keys Since 2018 Google Maps is no longer free. You must enable billing with a credit card and have a valid API key for all of your projects https:\/\/developers.google.com\/maps\/billing\/understanding-cost-of-use. This allows to get free usage of near 28K maps services requests monthly. Google requires mandatory Maps API keys for maps created on new [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":7212,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-17877","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-json\/wp\/v2\/pages\/17877","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-json\/wp\/v2\/comments?post=17877"}],"version-history":[{"count":5,"href":"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-json\/wp\/v2\/pages\/17877\/revisions"}],"predecessor-version":[{"id":18411,"href":"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-json\/wp\/v2\/pages\/17877\/revisions\/18411"}],"up":[{"embeddable":true,"href":"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-json\/wp\/v2\/pages\/7212"}],"wp:attachment":[{"href":"https:\/\/www.salephpscripts.com\/wordpress_maps\/demo\/wp-json\/wp\/v2\/media?parent=17877"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}