Google maps showing a blank screen after uplaoding the app into playstore. But Map showing when running locally(in emulator). I tried by changing the SHA1 of google map api by Playstore app signing certificate SHA fingerprint but still showing the blank screen.
Please run the app first in real device and if it working then do as follow.
If u have enabled the App Signing Feature in the Developer Console, then it's clearly written in the documentation that the Upload Certificate is only needed by Google for authentication and that upload certificate is removed before installing the application on the user's phone. So, u also need to give the App Signing Certificate SHA under the key which you have enabled for Google Maps API. The App Signing Page is as I have attached the screenshot for your convenience... In the image I have marked which you need to give as additional credentials
Thanks for all the answers.
There are two google_maps_api.xml files in the app one for debug and another for release.
release : app\src\release\res\values\google_maps_api.xml
debug : app\src\debug\res\values\google_maps_api.xml
In my case the api key was blank in release google_maps_api.xml
According to me the SHA1 keys are different for debug key and release key. But it will not work after upload on play store. To visible map you should follow the steps. - go to https://play.google.com/apps/publish/signup In that go release option. Copy SHA1 key from App signing certificate - Paste it while Editing API key which is generated for your app. Note : Your API should present into both debug and release xml file.
You can obtain a SHA1 key for release so easily.
in your Gradle enter your release key details like this.
signingConfigs {
release {
storeFile file("F:/Development/release_myapp.keystore")
storePassword "231232das"
keyAlias "myapp_rel"
keyPassword "dasd333_das"
}
}
Then run signingReport in Gradle task:
You will get release SHA in run window.
If you've opted in for Google Play App Signing Feature, You have to another one SHA key to your console which is generated by google. Follow the Zoffa answer to get that.
For more info Source: http://devdeeds.com/create-sha1-key-using-android-studio/
来源:https://stackoverflow.com/questions/46191073/google-maps-not-showing-after-uploading-the-app-to-playstore