Backup And Restore iPhone Text Messages
An iTunes backup includes text messages. See this Apple page for what is included. Notice that to restore everything, including passwords, you need to encrypt the iTunes backup with a password.