You can backup your text messages on iPhone using iCloud or iTunes and on Android using Google Drive or third-party apps like SMS Backup & Restore, SMS Organizer, etc.