Resetting your iPhone to factory defaults will erase all your content and settings and restore the state as if it were new. However, there are a few extra steps you should take if you want to get rid of your iPhone.
What does resetting to factory settings do?
As the name implies, resetting to factory settings deletes everything from your phone and runs it back to what it was when you first got it ̵
Resetting to Factory Defaults will not reinstall your iPhone's software from scratch. If you fix problems with your device and can not resolve the issue by factory reset, you can try reinstalling your iPhone's operating system.
If you want to sell your phone or change platform, there are some other things you should do in addition to a factory reset.
Disable Find My iPhone
If you reset your device because you want to sell or give it away, you need to disable Find My iPhone. On iOS 7, Find My iPhone is also used as an activation lock. That is, if "Find My iPhone" is enabled, you can only set up the phone again . Luckily, switching off is easy.
Open the Settings app and tap on the top of your name.
Tap iCloud> Find My iPhone.
<img class = "alignnone wp-image-426534 size-full" data-pagespeed-lazy-src = "https://www.howtogeek.com/wp-content/uploads/2019/06/reset_iphone_FMI_step4-1 .png.pagespeed.ce.iXWDRBrh_b.png "alt =" Tap Find my iPhone When prompted, tap "Turn off."
There is an additional step option if you change the platform (from iOS to Android) – you also need to log out of iMessage.
If When you switch to platform, you must log out of iMessage
When an iPhone user sends a message to another iPhone user, Apple uses iMessage by default, so if you switch to Android and you do not sign out of iMessage, the sending iPhone will continue believe you have an iPhone, your messages end up in the "iMessage Abyss", instead of being converted to SMS / MMS and sent to the Android phone.
To unregister iMessage, open the app settings, scroll down and tap "Messages" 
Tap the switch next to "iMessage" to turn it off.
Your phone number is now logged out of iMessage and you can continue with the factory reset. If you missed this step before you got rid of your iPhone, do not worry. You can visit Apple's self-help website and submit your phone number for unsubscribe. You will receive a free SMS with a verification code. Enter the code and you're ready to go.
With these things out of the way, you can reset your phone.
Perform full reset to factory settings.
When you're ready to reset the device, open the app settings and tap General.
Scroll down and touch Reset> Clear all content and settings.
If you have a passcode, you will be prompted to enter it. Touch "Delete iPhone".
Tap "Delete iPhone" a second time.
Done! Your phone will be processed for a few minutes. Once it's available again, you'll be asked to rebuild your iPhone.