Before you sell us iPhones or iPads.
You need to remove your personal information from them. Don’t manually delete your contacts, calendars, reminders, documents, photo streams, or any other iCloud data while you’re signed in to iCloud with your Apple ID (because this will delete your content from the iCloud servers and any of your devices signed in to iCloud).
If you paired an Apple Watch with your iPhone, unpair your Apple Watch.
Back up your iOS device.
Tap Settings > iCloud. Scroll down and tap Sign Out. In iOS 7 or earlier, tap Delete Account.
Tap Sign Out again, then tap Delete from My iPhone and enter your password.
Go back to Settings and tap General > Reset > Erase All Content and Settings.
If you turned on Find My iPhone, you might need to enter your Apple ID and password.
If asked for your device passcode or Restrictions passcode, enter it. Then tap Erase [device].