To reset your iPhone or iPad:
- Go to Settings
- Scroll to Reset
- Select Erase All Content and Settings.
After typing in your passcode (if you've set one), you'll get a warning box, with the option to Erase iPhone (or iPad) in red. Click the Erase warning.
You'll need to enter your Apple ID password to confirm the action.
The device will be wiped and go back to the initial setup screen you saw when you first used the device.
You can also fully reset your iPhone or iPad through iTunes.
When you plug in your iOS device, you should be able to see a 'Restore iPhone' button, which will fully reset the device.