A factory reset of your iPhone erases all of your content and settings, reverting it to a like-new state. However, there are a few extra steps you should take if you plan to get rid of your iPhone.
What Does a Factory Reset Do?
As the name implies, a factory reset wipes everything from your phone and takes it back to the way it was when you first got it—you know, like it’s straight from the factory. It erases all your photos, apps, accounts, videos—nothing will be left. A factory reset takes several minutes to complete. Once it’s done, you’ll be prompted to set up your iPhone like it’s new.
What a factory reset does not do is completely reinstall your iPhone’s software from scratch. If you’re troubleshooting your device and a factory reset doesn’t solve the problem, you can try reinstalling your iPhone’s operating system.
If you plan to sell your phone or change platforms, though, there are a couple of other things you should do in addition to a factory reset.
Disable Find My iPhone
If you’re resetting your device because you want to sell it or give it away, it’s essential to turn off “Find My iPhone.” As of iOS 7, “Find My iPhone” also serves as an activation lock. This means if “Find My iPhone” is on, only you can set up the phone again. Fortunately, turning it off is easy.
Open the Settings app and tap your name at the top.
Tap iCloud > Find My iPhone.
Read the remaining 23 paragraphs
Source : What to Do Before Selling, Giving Away, or Trading Your iPhone