Moving apps together with their internal data is a frequent need when you upgrade to a new Android phone. Google’s built‑in backup works for many apps, but it often skips game progress, custom settings, or apps that disable cloud sync. The adb backup command offers a reliable, no‑root way to capture an app’s APK and its private data, then restore it on another device.
Make sure you have the following:
adb backup was deprecated in Android 12, but it still works on most devices up to Android 11; on Android 12+ you may need to enable the hidden adb_backup flag (see troubleshooting).Both phones need USB debugging turned on.
Connect the source phone to your computer via USB. If you prefer Wi‑Fi, run adb tcpip 5555 on the device first, then connect with adb connect IP_ADDRESS.
adb devices
You should see a line like xxxxxxxxxxxx device. If it shows unauthorized, check the phone for a dialog asking to allow USB debugging and tap Allow.
The adb backup command can target a single package, a list of packages, or all user apps. Use the package name (e.g., com.example.game) which you can find in Settings > Apps > App name > Advanced > Package name, or via adb shell pm list packages.
com.chucklefish.stardewvalley.Run the backup command on the source device. The -apk flag includes the APK file, -shared includes shared storage (photos, downloads) for the selected apps, and -all backs up every user app. For a selective backup, list the packages after the command.
# Backup a single app with its data and APK
adb backup -apk -f ~/stardew_backup.ab com.chucklefish.stardewvalley
The device will display a confirmation screen. You can set a password to encrypt the backup (recommended) or leave it blank for an unencrypted file. Remember the password – you’ll need it for restoration.
If you want to back up multiple apps at once, separate the package names with spaces:
# Backup three apps together
adb backup -apk -f ~/myapps_backup.ab com.example.app1 com.example.app2 com.example.app3
For a full user‑app backup (excluding system apps), use:
# Backup all user-installed apps
adb backup -apk -shared -all -f ~/full_backup.ab
During the process, the phone may show a progress bar. Large games can take several minutes.
After the backup finishes, check the file size on your computer. A size of a few kilobytes usually means the command failed or you chose no apps.
ls -lh ~/stardew_backup.ab
Typical game backups range from 100 MB to a few gigabytes, depending on saved data.
If you used a password, you can test decryption with the adb restore command in “dry‑run” mode (no actual restore) by adding the -noauto flag and cancelling when prompted.
There are three safe ways to move the .ab file:
python -m http.server) on your PC and download the file on the phone.Place the file in a folder you can easily locate, such as /Download or /Documents.
Repeat the steps from Step 1 on the new device. Connect it to the computer (or use Wi‑Fi ADB) and verify the connection with adb devices.
Run the restore command, pointing to the backup file you transferred. If you set a password during backup, you’ll be prompted for it.
# Restore a single app
adb restore -f ~/stardew_backup.ab
When the phone shows the “Restore data?” screen, tap Restore. The device will reinstall the APK and write the saved data to the app’s private directory.
For a full user‑app backup:
# Restore everything that was backed up with -all
adb restore -f ~/full_backup.ab
After restoration, the phone may reboot automatically. Once it boots, open the restored app to verify that your settings, progress, or login state are intact.
After confirming a successful transfer, you can delete the backup file from both the computer and the target phone to avoid leaving sensitive data exposed.
sdelete on Windows or shred on Linux) to prevent forensic recovery.If adb backup fails because the device runs Android 12+ with the feature disabled, you have two practical work‑arounds:
Both alternatives store data in the cloud, which may not meet privacy‑focused users’ requirements.
adb backup. Skip those and reinstall from the Play Store.-pw flag (e.g., adb backup -apk -f backup.ab -pw mySecret).With these steps, you can reliably move your favorite apps and their precious data to a new Android device without rooting, without relying on cloud services, and with full control over what gets transferred.









