February 9, 2021 · Adv. Pen-Testing Pentest Android

Install apks / apk in Android via adb

  1. Enable network connect in your Android Settings, you can just search adb and you will find the setting.

adb root
adb connect
adb remount
adb push to_install.apk /sdcard/Downloads/
adb shell
cd /sdcard/Downloads/
mv to_install.apk /data/local/tmp/
cd /data/local/tmp/
pm install to_install.apk

adb push to_install.xapk /sdcard/Downloads/
adb shell
cd /sdcard/Downloads/
mkdir temp_install_dir
unzip to_install.xapk -d temp_install_dir
mv temp_install_dir /data/local/tmp/
cd /data/local/tmp/temp_install_dir/
pm install to_install.apk