Reputation: 11
I get a release android key, which is a Release certificate(SHA-1 fingerprin), but it is till not working for my release.apk, the debug key(Debug certificate) works fine. I don't know why, does anyone know? Please help!
Upvotes: 0
Views: 770
Reputation: 39
Just check your google_maps_key under the src/release directory, you should place there your own key from the google console (the one you got with the release fingerprint SHA1).
This happens because the default google_maps_key file you access is the one of the debug, so the release key will never notice this, you must place it on your release version of google_maps_key.
Upvotes: 1
Reputation: 5565
1- Create apk file using "Use the export Wizard" in "Android Manifest" file of your project.
2- After inserting key and before finishing, MD5 and SHA1 keys are shown as shown is this given pic-
3- Create new API Key for Android project for new SHA1 which is retrieved in point 2.
4- Use that API key in manifest file as shown below
5- Clean your project and build APK file again.
6- You can see google maps now in that apk.
Upvotes: 0
Reputation: 771
You can't use a debug key for a release.apk, you need a release key for publish you apk!
Read this documment, https://developers.google.com/maps/documentation/android/start#the_google_maps_api_key and you will find you answers!
Good Luck!
Upvotes: 0