Transfer APK from Phone to PC And PC to Phone

In the life of Mobile Automation there will be many situations where it is required to transfer an apk file from device to computer and vice versa. Even with Appium automation it is required to have the apk file on the system as well, so that the scripts can target Appium to it. You must have notice the below line of statements in Appium Automation Scripts:

Java

1

2

3

File classpathRoot=newFile(System.getProperty("user.dir"));

File appDir=newFile(classpathRoot,"/Apps/Amazon/");

File app=newFile(appDir,"in.amazon.mShop.android.shopping.apk");

There are multiple ways to get the apk files on the computer. One can even download the same from internet and can be transfer from phone to PC and even there are multiple ways to transfer the app from phone to PC, let look at at some easy ways for now.

How to Transfer APK from Phone to PC

Prerequisites for this:

App should be installed on the device, use GooglePlay store to install any required app on the device.

1. Download and Install Easy Backup & Restore application highlighted below from Google Store. (This is one of the easiest to use backup apps).

2) This will hardly take few seconds to install on the device. Once done, click on the Apps Tools.

Note:Other Back Up app can also be used and almost works similar to this app, the only difference can expect is the default Back Up location and that can be find out from the app settings.

3) Select the application you would like to export the APK file and tap on the BACKUPbutton at the bottom of the first screen shot. For the sake of this example, I am using Amazonapp.

4) This will take few seconds to produce the backup on the device of the selected app can be seen on the second screenshot. Once done the app will display the successful message, proceed with clicking on OK button.

5) Browse to My Computer, look for the connected device and open it.Note: In case the device is not displayed, please restart the computer and device as well to try again. Please visit this to look at the steps to connect the Android device with Computer.

6) Go in to the Phone Store.

7) Look for the folder ‘App_Backup_Restore‘ and get in to that.Note: In case of using other Back Up app, can look forbackups folder to check for the apk back up and some of the apps create back on the path SDCard/backups/app/ instead of saving it on Phone memory. Please look carefully.

8) Notice that the Back up for the selected app is created in this folder. Now this can be moved to any location in the computer by copy pasting the apk file to another location or simply using drag and drop.Note:

Same task can be done by using other BackUp apps like APK Extractor, Save Master, or Super Toolbox.