My app uses Google Maps, I signed up for a Google Maps key to debug, it worked. But now, I need a Google Maps key in release mode, before publishing. How can I get it?
Getting a key itself is free, and Google offers a limited free trial that includes $300 in credit for your first 90 days of use. After your trial, Google will provide $200 of credit per month toward your Maps API usage.
You may use an unrestricted API key with any Google Maps Platform API or SDK. However, we strongly recommend that you restrict your API keys, especially in following scenarios: The test environment will be or is publicly visible.
If you're building a GCP application, see using API keys for GCP. When you use API keys in your Google Cloud Platform (GCP) applications, take care to keep them secure. Publicly exposing your credentials can result in your account being compromised, which could lead to unexpected charges on your account.
You need to :
Create your own signing key that you will use for publishing, using Keytool : http://developer.android.com/guide/publishing/app-signing.html#cert
Get the MD5 fingerprint of your newly generated key : https://developers.google.com/maps/documentation/android/mapkey#getfingerprint
Submit the signature to this link to get your Google Maps key : https://developers.google.com/android/maps-api-signup?hl=fr
Export your application with your newly created key, in Eclipse : right click on your projet -> Android Tools -> Export signed application package.
Be careful to keep your certificate in a safe place, because you will need it if you want to publish an update of your app on Google Play.
EDIT :
For the Google Maps Android V2, the signing is a little different. You will need to get the SHA-1 signature and provide the package name of your application as well. A Google APi account is moreover needed. All info are given on this page : https://developers.google.com/maps/documentation/android/start?hl=fr#the_google_maps_api_key
Before publishing application into play store you have to follow some step to create release key.
Step 1: First find your key store location. Ex. D:\Harshid\testKeystore
Step 2: Run this command.
keytool -list -v -keystore D:\Harshid\ testKeystore -alias D:\Harshid\ testKeystore
please used fully qualified name of keystore.
Step 3: Copy SHA1
Step 4: Follow this google map api console.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With