While we are implementing a feature to display the cache size in app for users, we think that there should be a simple function in Android to convert bytes to readable format. So what we got is android.text.format.Formatter.formatFileSize(Context context, long bytes) Looks good, it takes a Context object, a little bit annoying though. But then the interesting part comes up. When I deploy the app on a 7.1 device, it behaves as expected like 10,73,741,824 bytes is showing 1.0 GB, but later when my colleague testing on his 8.1 device, it shows something like 1.1GB