There are apps to be able to backup and restore SMS and MMS from and to your phone. But the backup restore procedure can also be done by using Android Debug Bridge. This is a very good solution if your screen or something else is broken on your phone so that you cannot use any backup app.
The SMS and MMS database is located in the file mmssms.db in /data/data/com.android.providers.telephony/databases on your phone. To copy mmssms.db from your Android phone and then paste it to you phone, it needs to be rooted.
But what about the MMS images and pictures? I you only backup the mmssms.db file with ADB your MMS pictures will be lost. If you open you mmssms.db file in an SQLite browser you can see where your images are saved on your device. On the devices that we have looked into the pictures are saved in /data/data/com.android.providers.telephony/app_parts/
Backup and restore SMS and MMS via Android ADB – The steps
ADB backups can be made when the phone is booted into Android or in recovery. Restore shall be made when the phone is booted into Android.
- Get access to your phone as root:
adb root - Backup the SMS and MMS database from your phone:
adb pull /data/data/com.android.providers.telephony/databases/mmssms.db - Backup the MMS images from your phone:
adb pull /data/data/com.android.providers.telephony/app_parts/ - Restore the SMS and MMS database to your phone:
adb push mmssms.db /data/data/com.android.providers.telephony/databases/ - Make sure that the folder app_parts exists in /data/data/com.android.providers.telephony/databases/. Otherwise create it using:
adb shell mkdir /data/data/com.android.providers.telephony/app_parts/ - Restore the MMS images to your phone (if your images are saved in the folder app_parts on you PC):
adb push app_parts /data/data/com.android.providers.telephony/app_parts/
Restart the phone you restored you SMS and MMS to and your SMS and MMS should be restored.
oh, gee, if it were rooted I wouldn’t need to backup this way
now how to I backup z3 sms without root and a broken screen
NOTE: on some phones the file path could be different – not /data/data/com.android.providers.telephony/databases/mmssms.db but /data/user_de/0/com.android.providers.telephony/databases/mmssms.db