Erasing an iPhone is a straightforward process but should be done carefully. Go to Settings > General > Transfer or Reset iPhone > Erase All Content and Settings. This will delete everything, so make sure to back up your data first. Are you erasing it to sell, or is there another reason? Feel free to share more details if you’d like help with a specific step.