How to use microSD as internal storage in an Android phone



Older Android phones lacks good support for expanding internal storage when connecting a microSD external memory card.

This is a guide to make Android aware of you microSD and have it used as internal storage by default using an Ubuntu Linux computer.

This guide makes sense when the Android phone doesn't gives the option to use a microSD external storage card as an internal storage when you just connect it.

Install adb

adb is the Android's debugging tool that runs on Linux, to install it: sudo apt-get install adb.

Activate developer mode

In your Android phone enable the Developers menu.

  1. Open the Settings app.
  2. Scroll to the bottom and select About phone.
  3. Scroll to the bottom and tap Build section 7 times.
  4. Return to the previous screen to find Developer options near the bottom.

Enable debugging

Enter the new Developer menu item and enable debugging through USB cable.

Connect phone to PC

After having the adb tool installed, we connect the phone through an USB cable and check it is being detected by adb with adb devices -l.

If it says unathorized like above, then trying to access the phone will fail with the following message.

So you should check phone's screen and accept to handle the smartphone through the computer.

Format microSD

Now we log into the phone through adb shell and execute the following commands.

We can choose to use 60% of the microSD memory as internal storage with the above command sm partition disk:179,128 mixed 60 or make Android use all the available external storage as internal storage with private like sm partition disk:179,128 private.

Move data to internal storage

  1. Go to Settings and then Storage.
  2. Select the microSD card listed at the internal storage section and tap to enter it.
  3. Inside the above menu browse to the bottom and choose to move all the data to the new card.


Remove all the data from previously stored apps, and manually check they are located in the new position.

Also check that Camera default storage is the newly chosen internal or external storage as you prefer.


Marcelo Canina
I'm Marcelo Canina, a developer from Uruguay. I build websites and web-based applications from the ground up and share what I learn here.
comments powered by Disqus


    • How to use microSD as internal storage in an Android phone