Contacts are easy. Just make sure you’ve set up the iPad with the same account that you use for you contacts on the iPhone, whether that be an Apple iCloud account, Google Account, or other. If you have never synced your contacts with an account, you can do so not on the iPhone. Just make sure that you choose to keep your contacts rather than delete/discard them when adding the account. You will find account setup under the Mail, Contacts, and Calendar options. You can use any of these to add and account, or turn on/off services for that account.
Message history is different. I don’t know of any way to sync old message history. You can add your iPad to Text Message Forwarding on your iPhone in its Message settings to make sure they are in sync for new messages.