


Now, only apps signed with the firmware's key can hold this permission. The protection level of _APP_CACHE changed from "dangerous" to "signature|privileged" or "system|signature" in Android 6.0+. Is there an option to delete the cache of all apps or certain apps in Android M?Ī third-party app cannot delete the cache of another app in Android 6.0+. Like the excepted answer explains, there seems to be no way to delete tha App Cache without root on Devices with Android M and above. But the Settings app can clear the Cache of certain apps It can't be the new method: public abstract void freeStorage(String volumeUuid, long freeStorageSize,īecause I think it does not delete the Cache of certain apps, but of enough apps to clear the expected ram size. How does the Google Setting App handle it ? Is there really no way, to delete App Cache on devices with Android M ? Required for cleaning of internal cache, Cache Cleaner is not able toĬlean internal cache on Android 6.0 and newer. Longer available to regular applications and since this permission is Starting with Android 6.0, CLEAR_APP_CACHE permission seems to be no Partial incompatibility with Android 6.0 and newer There is an open source cleaner on GitHub, which stopped development with this reason: But on devices with Android 6.0 it results in this exception : Wrong number of arguments expected 3, got 2 This Code works fine on devices lower than Android 6.0. Long desiredFreeStorage = 8 * 1024 * 1024 * 1024 // Request for 8GB of free space Method methods = pm.getClass().getDeclaredMethods() Seems like most ways don't work anymore in Android M.Īs a reference I used this Code out of this discussion :Īndroid: Clear Cache of All Apps? PackageManager pm = getPackageManager() Is there an option to delete the cache of all Apps or certain Apps in Android M ?
