sodcalculator

10 Tech How-To

Find Deleted Android Data Before Overwrite

Guide 10-53696 · Updated · Step by step

If you deleted a file on Android and haven’t written much new data since, it may still be recoverable from the device’s flash storage until the system reuses those blocks. The key is to stop using the phone immediately, enable Airplane Mode, and scan the internal storage with a recovery tool that reads raw blocks, because the longer you wait, the higher the chance the data is overwritten.

Why Deleted Data Survives (Briefly)

Android stores files on flash memory (eMMC or UFS) with a filesystem like ext4 or F2FS. When you delete a file, the system doesn’t erase the actual data bytes; it simply marks the space as free in the filesystem’s metadata. The original content remains intact until the system writes new data over those exact blocks. This is why recovery is possible—but only if you act before the storage controller’s garbage collection or new app writes reuse the space.

The window is unpredictable. It could be minutes on a heavily used phone or days on a device that’s been idle. Even background processes (syncing, indexing, notifications) can trigger writes. The safest approach is to power off the phone and remove the microSD card if the data was on external storage—but for internal storage, you can’t simply remove it, so you must disable all writes.

Where the Deleted Data Actually Lives

On Android, deleted files remain in one of three places depending on where they were stored:

  • Internal storage (userdata partition) – The bulk of your apps, photos, downloads, and documents. This is the most common location and the hardest to recover because the partition is encrypted on modern devices.
  • microSD card (external storage) – If you used a removable SD card, the deleted file stays on the card’s flash memory. You can remove the card and connect it to a computer for recovery with desktop software, which is often more reliable than on-device tools.
  • App-private directories – Files an app created in its own internal folder (e.g., /data/data/com.app/) are deleted when the app is uninstalled or when the app itself deletes them. These are also recoverable in theory, but require root access to reach.

Additionally, Android’s “Recently Deleted” folders in apps like Google Photos or Samsung Gallery act as a temporary holding area—files are moved there, not truly deleted, and can be restored without any special tools for 30–60 days.

How Recovery Works on Android

Recovery tools scan the raw storage blocks for signatures of known file types (JPEG, PNG, PDF, etc.) and reconstruct the file from the remnants. On a non-rooted phone, apps like DiskDigger (which can run without root for photos/videos) use a less invasive method: they read the free space through the Android Storage Access Framework, which only works for media files and only if the app has permission. For full file recovery (documents, APKs, databases), you need root access, which allows the app to read the entire userdata partition directly.

The process on a rooted phone typically involves:

  1. Installing a recovery app that requests root permission (e.g., DiskDigger, Undeleter).
  2. Selecting the partition to scan (usually /dev/block/mmcblk0pXX for userdata).
  3. Choosing a quick scan (checks the free space only) or a full scan (reads the entire partition, which can take hours).
  4. Reviewing the list of found files and saving them to a different storage location (never the same device).

If you don’t have root, your only option is to use a PC-based tool that connects via USB debugging (ADB) and reads the partition through a custom recovery like TWRP. That requires unlocking the bootloader, which wipes the device—so it’s a catch-22 for data recovery. In practice, most non-rooted users can only recover media files that were in the free space and not encrypted.

Encryption: The Biggest Hurdle

Since Android 6.0 (Marshmallow), full-disk encryption is mandatory on new devices (and file-based encryption since Android 7.0). This means the data on the userdata partition is encrypted with a key stored in the device’s hardware (TEE). When you delete a file, the encrypted blocks remain, but they are unreadable without the key. On a rooted phone, the recovery app can access the decrypted data only while the device is booted and the key is in memory. On a non-rooted phone, the app can’t read the raw partition at all, so it can only see the files the OS lets it see—which are already decrypted but also already marked as deleted.

Practical implication: if your phone is encrypted (most are), on-device recovery without root is limited to files that the system hasn’t yet purged from the free space and that the app can access via the media scanner. For anything else, you’d need to have backed up the data or have the encryption key—which you don’t.

What to Do Immediately After Deleting

Your chances of recovery drop with every passing minute. Follow these steps in order:

  1. Turn on Airplane Mode to stop network syncs, messages, and cloud backups.
  2. Do not open any apps, take photos, or download anything.
  3. If the file was on a microSD card, remove the card and set it aside.
  4. If the file was in internal storage, power off the phone completely—do not just lock it.
  5. Boot into recovery mode (if possible) and use a PC to run a recovery tool via ADB—but note that this may require unlocking the bootloader, which wipes data.
  6. If you have root, install a recovery app before you need it (so it’s ready), then run a scan.

If you can’t root, your best bet is to use a cloud backup you already had (Google Photos, Drive, etc.) or check the app’s own trash folder. Many apps (WhatsApp, Gmail, Notes) have a “Recently Deleted” or “Trash” feature that keeps files for 30 days.

Tools and Their Limitations

Several Android apps claim to recover deleted files, but their effectiveness varies:

  • DiskDigger – Runs without root for photos and videos only. With root, it can recover other file types. Free version has limits; paid version is more capable.
  • Undeleter – Requires root for full scans. Can recover any file type but the free version caps the scan size.
  • Dr.Fone – PC-based tool that works with non-rooted phones via ADB, but it only scans the free space and often fails on encrypted devices.
  • Recuva (PC) – Can recover files from a microSD card when connected to a computer, but not from internal storage unless you create a full image of the partition (which requires root).

No tool can recover data that has been overwritten. If you’ve used the phone for even a few minutes after deletion, the original file may be partially or fully destroyed. The only reliable way to “find” deleted data is to have a backup—Google One, Samsung Cloud, or a local backup to a PC.

Frequently Asked Questions

Can I recover deleted files without rooting my Android?

Only for media files (photos, videos) if the app has access to the free space via the Android media scanner, and only if your device isn’t encrypted. For documents or app data, root is required to read the raw partition. If you’re not rooted, check the app’s trash folder or cloud backup first.

How long does deleted data stay on Android before being overwritten?

There’s no fixed time. It depends on how much new data you write, the device’s storage controller, and whether TRIM/garbage collection runs. On an idle phone, it could last days; on an active phone, minutes. Treat it as gone after a few hours.

Does factory reset delete everything permanently?

A factory reset marks the entire userdata partition as free, but the old data remains until overwritten. However, on modern encrypted devices, the encryption key is discarded during reset, making the old data cryptographically unrecoverable—even with root. So for practical purposes, factory reset makes data unrecoverable.

Can I recover data from a dead Android phone?

If the phone won’t boot, you can try connecting the storage chip to a computer using a JTAG or chip-off method, but that’s expensive and requires specialized equipment. For most people, the data is lost unless it was backed up.

Is it safe to use a recovery app from the Play Store?

Most are safe, but they require broad storage permissions. Be cautious: some apps are adware or request unnecessary permissions. Read reviews and stick to well-known tools. Never grant root access to a suspicious app.

Related

General steps for current mainstream versions; menus can differ by device and version. See the disclaimer or report an error.

More in this bed

The whole Tech How-To bed →