Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to change the package name of an app in android studio linked to firebase

I created a android app which is linked to Firebase . But i forgot to give package name so by default it took "com.example.abc.appname" . Here the problem is when i am uploading app in google playstore its not accepting release apk with generated with that file name.

  1. So how to change package name without getting any conflicts as it is linked to firebase.
  2. There is also a problem with google plus login its working fine with debug mode but failing to authenticate with release mode.I did not find any solution.App is in the release phase and i am facing these problems.
like image 979
maneesh Avatar asked Mar 09 '23 01:03

maneesh


2 Answers

You can't change the app data in the console. You'll have to delete the app and add a new one with the correct package name and SHA-1 as necessary. You'll have to recreate any information directed at the app, such as Remote Config parameters. This will not delete any data associated with the project, such as database values or Cloud Storage.

like image 131
Doug Stevenson Avatar answered Apr 30 '23 10:04

Doug Stevenson


change your package name from studio and then after you have to create new app in firebase with new package name. Otherwise you have to change package name in firebase and for existing project and replace json file in your studio.

Keep in mind you also have to replace your google-services.json. an make sure that com.example package not accept by google while you upload app in playstore. i suggest that you have to give package name like com.yourappname.

like image 31
Mehul Kabaria Avatar answered Apr 30 '23 10:04

Mehul Kabaria