Update an Android app (without Google Play store visit)
Absolutely. You will need to build a mechanism, though, for your app to call home to the server, find out if there's a newer version of the app, and if there is, pull it down and install it. Once you've determined that you do need to pull down an update, you can do that with something similar to this AsyncTask:
protected String doInBackground(String... sUrl) {
String path = "/sdcard/YourApp.apk";
try {
URL url = new URL(sUrl[0]);
URLConnection connection = url.openConnection();
connection.connect();
int fileLength = connection.getContentLength();
// download the file
InputStream input = new BufferedInputStream(url.openStream());
OutputStream output = new FileOutputStream(path);
byte data[] = new byte[1024];
long total = 0;
int count;
while ((count = input.read(data)) != -1) {
total += count;
publishProgress((int) (total * 100 / fileLength));
output.write(data, 0, count);
}
output.flush();
output.close();
input.close();
} catch (Exception e) {
Log.e("YourApp", "Well that didn't work out so well...");
Log.e("YourApp", e.getMessage());
}
return path;
}
// begin the installation by opening the resulting file
@Override
protected void onPostExecute(String path) {
Intent i = new Intent();
i.setAction(Intent.ACTION_VIEW);
i.setDataAndType(Uri.fromFile(new File(path)), "application/vnd.android.package-archive" );
Log.d("Lofting", "About to install new .apk");
this.context.startActivity(i);
}
How to update content of the app without publishing new version to Play Store
In order to change content dynamically without updating the app, you need to use something like Firebase Remote Config. Read the link it will help you changing the values, content, and what you need without uploading code to Play Store.
It works for android and iOS as you need.
How to autoupdate android app without playstore? Like Facebook app or any Contest app
If you would like to check if you app has updates (without interacting with Google Play), you'd have to poll a server (providing your current version) and let the server check if there is a newer version available. If that is the case, let the server respond with a changelog and an url to the newer version.
Luckily, there are libraries to do this:
- AppUpdater. Android Library that checks for updates on your own server (or Google Play, Github, etc). Great documentation. This library notifies your apps' updates by showing a Material dialog, Snackbar or notification.
- Android Auto Update. Chinese library, but should do the trick, one of the most popular libraries to do this, but this can be just because Google Play is not available in China.
- AppUpdateChecker A simple non-Market way to keep your app updated.
All it requires to set up is a URL pointing to a JSON document describing your app's changes. - Auto Updater This project allows to automatically update a running APK application using a private update server (see apk-updater) instead of Google Play updater. Also comes with a server script.
- SmartUpdates. Older library, but instructions in English and also provides a server script.
- WVersionManager. Checks for updates, but actual update has to be downloaded from the Play Store.
Update Android Application Outside of Google Play
See this link... Hope it helps.. Try it..
It says that we have to create mechanism, that calls the server and checks for newer versions..
Auto-update of Android app, without asking a user
You cannot silently install applications on an unrooted Stock Android device for security reasons. It is even clearly stated by Dianne (a Google Employee) here.
Related Topics
Viewpager with Google Maps API V2: Mysterious Black View
Version Conflict Updating to Play-Services 9.4.0 Android Studio 2.2
Intel's Haxm Equivalent for Amd on Windows Os
Failed to Resolve: Com.Android.Support:Appcompat-V7:27.+ (Dependency Error)
Android Webview Style Background-Color:Transparent Ignored on Android 2.2
How to Determine If Network Type Is 2G, 3G or 4G
Change Toolbar Color in Appcompat 21
How to Get the List of Mounted External Storage of Android Device
Failed to Find Style 'Coordinatorlayoutstyle' in Current Theme
Textwatcher for More Than One Edittext
How to Rename the Android Package Name
How to Generate a Thumbnail from a Video Url in Android
Bitmap Recycle with Largeheap Enabled
Get Only Email Address from Contact List Android
How to Get a Working Vertical Seekbar in Android
How to Show an Activity Before My App Is Uninstalled (Android)