简体   繁体   中英

Update app via Google play, which is installed by APK file

I have an app that is not deployed via Google play store.

It has it's own APK file server, and previously, it doesn't have "update" functionality. Because of it is special purpose app, so a user who need to update app, he need to just uninstall current app and install new app.

Now I need to update these already installed app via google play.

Question is: Can I update app via Google play store, that is installed via APK file?

Tested environment:

  • Google play service 11.7.46
  • Play store 8.4.19
  • Galaxy S7
  • Released Koeran market only.


I tried:

1) Build three test APK Versions 1, 2, 3.

2) Deploy Version 2 and update Version 3 via Google play store.

3) [FAILED] Install APK Version 1 via ADB, and cannot update via Google play store. (In google play page of my test app, I can see buttons "UNINSTALL / OPEN"

This is exactly what I want to do.

4) [FAILED] Install APK Version 2 via ADB, and cannot update via Google play store. (In google play page of my test app, I can see buttons "UNINSTALL / OPEN"

Some of my colleague said this case is possible, but I couldn't achieved.


I found difference between signed APK and Google play extracted APK. By binary compare , many file was different.

比较图像

Especially AndroidManifest.xml, this information was added in Google play-extracted apk.

<meta-data
    android:name="com.android.vending.derived.apk.id"
    android:value="1" />

It was possible to update old version apk that was downloaded from google play publish page.


I found below answer, but it seems not working in my case.

Will apk installed manually (not from play store) receive notification when update becomes available?

you will receive updates / see the app in the Google Play "installed apps" tab only if the two conditions will take place:

the APK package name is the same as the one uploaded to Google Play

the keystore used to sign the app in the play store is the same keystore used to release the apk you install manually.

In order to be updated by Play, the app has to be in the "User's library". This is a hard concept, but basically comes down to "has the user ever installed it from Play on any device". If the user has it in their user library, and the signature is the same as the signature on the Play store then the app will update.

If the user has never installed it from Play, then Play won't update it.

So what you want to happen won't happen, unless the user has previously installed it from Play on any device.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM