Search code examples
androidapkandroid-permissionsandroid-install-apk

Application is not installed (3rd party apk)


I want to install Android application from a 3rd party (not from Google Play). For testing purposes, I've downloaded .apk archive to my device via Google Drive. Google Drive has permission to install unknown applications. I've granted Google Drive that permission. However, 3rd party app is not installed. When clicking on the `.apk' file from Google Drive's app, I got the usual warning dialog about dangers of installing 3rd party apps, then installation dialog with the progress bar, and then "App is not installed".

The 3rd party is me: I've developed the application. It installs on the hardware device via Android Studio without problems. I plan to distribute the '.apk' archive using my one distribution solution. Security is vital for this app, hence I devised my own distribution solution and don't want to rely on Google Play or any other similar service. And don't tell me that Google Play is secure. Avoiding usage of Google Play as a distribution service is a matter of principal for me.

  1. How to fix "App is not installed" problem I've described?

  2. Do you know if "click on apk to install" still works on Android 10 when it comes to 3rd party apps?

  3. Do you know how to have your own cake (app) and it it too (install it) without Google Play?


Solution

  • I know the solution to problem number 1. I've had this problem before. When downloading an apk of your app instead of installing it using Android Studio, you have to do some or all of the following:

    1. Make sure you uninstall the version that you already have installed using "uninstall for all users"
    2. Make sure the version number for the apk you're installing is greater than the one already installed(if you choose not to do the above)
    3. Sign the apk with some key. I can be a throw-away, it just needs needs a jar signature. I don't know why this was ever needed, until some point it worked for me to send people an unsigned version of my app, and then it stopped. Maybe it still works for other people, I dont know.

    I hope this helps. It kind of sucks that the error message is so useless.