Install android apps to SD card by default
This article was last edited over 3 years ago. Information here may no longer be accurate. Please proceed with caution, and feel free to contact me.
There’s a bit of a bad user experience when you run out of space to install new apps on your Android device. You may want to move newly installed apps to your SD card to free up space on-device, but you can’t download any apps in the first place if your device does not have sufficient storage space in the default installation location.
To get Android to install to your SD card by default, you can use the following command.
pm set-install-location 2
In order for this to work, you will need to use adb to connect to your device and issue commands. There are many tutorials online that explain how to install and use adb.
You can use this command to see what setting your device is currently using for install location, and what options are available.
pm get-install-location
Make sure you have an SD card inserted, with available space, before doing this. If not, then this will not work, and the error messages from your device will not be very clear in explaining what the issue is.
You may not have to reboot your device, but I found that I did.
After a reboot, all new app installations on my device default to the SD card.