How to find the amount of free storage (disk space) left on Android?
I am trying to figure out the available disk space on the Android phone running my application. Is there a way to do this programmatically? Thanks, Try StatFs.getAvailableBlocks . You'll need to convert the block count to KB with getBlockSize. Example: Getting human readable size like 1 Gb String memory = bytesToHuman(totalMemory()) /************************************************************************************************* Returns size in bytes. If you need calculate external memory, change this: StatFs statFs = new StatFs(Environment.getRootDirectory().getAbsolutePath()); to this: