If you accidentally deleted a text message on your iPhone iPad that you really would like to recover, you may still be able to recover the deleted SMS or missing iMessages using iExplorer.
The deleted SMS or iMessages might be stored in an iTunes backup which you could use iExplorer to browse your local iTunes backups and recover the text messages. You can check for any recent iTunes backups and view all of them in that computer user account by opening iTunes Preferences and go to the Devices tab. There will be a date/time column next to every iTunes backup next to the name of the iOS device. If you do see a backup that might contain the deleted texts and allow you to recover the SMS, iMessages and shared attachments such as photos or videos, just open iExplorer and click on Browse iTunes Backups on the screen asking to connect your iPhone or iPad, or if your device is connected, you'll see a Browse iTunes Backups section at the bottom of the left panel. Select the backup with your deleted SMS or iMessages that you want to restore and click on Messages underneath that backup. Then, you can follow the article and tutorial below for how to export them:
How to transfer iPhone text messages to computer
Tutorial: How to export iPhone text messages to a computer
If you don’t have a backup with the deleted SMS or iMessage texts, there is another possible way to recover some of the SMS and iMessage conversations directly from your iPhone or iPad's SMS database. When you delete text messages in iOS, those texts are just marked for deletion from the SMS database but aren't actually removed from it. To retrieve this file, just go to the Backup section of iExplorer with that iPhone or iPad connected with its USB cable choose Load Backup Data to make a backup or Back Up Now if one already exists for that iPhone or iPad. Then, once a backup is loaded, go to the Backup Explorer section on the left below Backup and navigate to HomeDomain/Library/SMS and drag the sms.db file to your Desktop. Then, open the sms.db file in a text editor such a Notepad on a PC or Text Edit on a Mac. Since it is in an SQLite database format, some of what you see will look like a lot of odd symbols but just scroll through and find the text from the conversations. You can use the Find function to search for keywords (Control-F on a PC and Command-F on a Mac)
Also, a Spotlight search on an iPad or iPhone will show results for recently deleted text messages, so you could view snippets of deleted SMS and iMessages when you search for any keyword that is in the deleted text conversation.