SHA1 Key for DEBUG & RELEASE ANDROID STUDIO MAC

DEBUG:

  1. Click on the Gradle tab on the right hand side of the view.

  2. Go to the ROOT folder -> Tasks -> android -> signingReport

  3. Double click, this will build with the signingReport and post in your bottom view your SHA1.

RELEASE:

  1. In android studio. Build -> Generate Signed APK... and click Next

  2. Copy your key store path and key alias.

enter image description here

  1. Traverse to the "bin" folder of the jdk path present in Java.

  2. Open terminal and enter:

    keytool -list -v -keystore "key store path" -alias "key alias"

  3. Enter your key password and this will print out your release SHA1.


Here is the new easiest way to find release SHA-1 or other certificates:

I assume that you have already built signed APK and uploaded it to developer console. Open google play console. Go to "Version Management", go to "Application Signing" and see your certificates.

Note: First google will ask you to activate "Application Signing" for your application.

enter image description here


To obtain SHA1 for DEBUG as well as RELEASE you have to add the key details in the signingConfigs of your gradle file,

see the example here