# Install Split APK Manually

Recently I got to know a thing called split apks, and found the slices as invalid apk files, only the base is. Unfortunately, this means the usual default package installer is unable to handle this, and as such I got to know another thing called SAI, a split apk installer, capable of working with or without root. However, being curious, I wondered how it all worked internally, and began to do a bit of research. I didn't get far, but I got to find out about pm install commands, and I happen to have root access which is apparently mandatory if I am to go this path, as the terminal won't let me run pm install-create without first running su.

The next step is pm install-write all the slices, and this is where I fall. The most obvious way for me was to cd to the directory of the slices and pm install-write them one at a time, which didn't allow me to do so, and it seems to be expecting an int rather than a directory string.

Questions (TL; DR):

1. Can I install split apks without any extra apps (in my example, SAI)?

2. Am I in the right direction with pm install commands?

3. If the answer to question 2 is yes, what am I doing wrong, and what should I be doing instead (it seems to want an int instead of a directory string, not sure how to convert)?

4. Are there any other methods I can explore (preferably rootless, but root is also fine)?

• Tested pm myself on Pie. Let's suppose that our package is called com.example.apk: you'd install it with pm install com.example.apk. Next, to install the split parts, you need to issue pm install -p com.example com.example.split.apk, where -p com.example refers to the package name of the base package, and com.example.split.apk is your split package. Let me know if it works for you. – Death Mask Salesman Apr 22 at 16:50
• @Salesman: I assume the question is about "App bundles" and if I remember correctly the different split-up APKs all have the same package name. Installing such a slit-aup app should be possible using bundletool. – Robert Apr 22 at 17:38
• @Robert Yes, seems like we're referring to the same thing. In that case, either bundletool from a computer or pm from a rooted device will do the job. – Death Mask Salesman Apr 22 at 19:46