How to factory reset iPhone, with or without your passcode
Here's how to factory reset iPhone: back it up, then open Settings, tap General, tap Transfer or Reset iPhone and tap Erase All Content and Settings. If you've forgotten the passcode, Apple also offers ways to erase the phone from the Lock Screen or with a computer. A lost phone can be erased from iCloud.com.

The short version
- A factory reset erases your content and settings and returns the iPhone to the Hello screen. Apple calls it Erase All Content and Settings.
- Back up first. Anything not in a backup or in iCloud is gone once the erase finishes.
- Selling or giving the phone away? Sign out of your Apple Account and erase it in Settings. Apple says that erase turns off Find My and Activation Lock.
- Forgot your passcode? Apple's Forgot Passcode? option on the Lock Screen can reset the phone without a computer if Find My is on.
- Need to restart a frozen iPhone? That's a force restart, which Apple lists separately from its erase steps.
What a factory reset does
Apple says erasing your iPhone securely removes your personal information, content and settings, and that the phone is "restored to factory settings." Apple Pay cards, photos, contacts, music and apps are deleted from the device, and iCloud, iMessage, FaceTime and Game Center turn off.
What stays: Apple says your content won't be deleted from iCloud when you erase the phone.
If you only want to fix a settings problem, you may not need a full erase. See the section on resetting settings without erasing, below.
Before you factory reset your iPhone
Back up first: a factory reset deletes everything on the phone. Apple recommends a backup so you can restore your data later, on the same iPhone or a different one.
- Back up to iCloud: open Settings, tap your name, tap iCloud, tap iCloud Backup, then tap Back Up Now. Apple's iPhone User Guide also covers backing up to a computer, with the Finder on a Mac or iTunes on Windows.
- Unpair your Apple Watch if you paired one with this iPhone. Apple lists this as a separate step before you erase.
- Know your Apple Account password. The erase asks for it.
How to factory reset iPhone in Settings
This is Apple's main method, and it needs no computer:
- Open Settings.
- Tap General.
- Tap Transfer or Reset iPhone.
- Tap Erase All Content and Settings.
- Tap Continue.
- Choose whether to keep or delete your eSIM, if you have one. Apple says that if you erase the eSIM, you need to contact your carrier to reactivate your plan.
- Enter your iPhone passcode.
- Wait for your backup to finish.
- Enter your Apple Account password and tap the done button on the keyboard.
- Wait for the iPhone to reset. The Hello screen appears when it's finished.
If you've forgotten the passcode, skip to the section on resetting without it, below.
How to factory reset iPhone with a computer
Apple's computer method erases the iPhone and installs the latest iOS. Apple says to use the Settings method if your iPhone works. To use a computer, prepare the phone first:
- Update your Mac or PC.
- Back up the iPhone.
- Turn off Find My: open Settings, tap your name, tap Find My, tap Find My iPhone and turn it off, then enter your Apple Account password.
Then restore it:
- Connect the iPhone to your computer with a cable.
- Open the Finder on a Mac or the Apple Devices app on a Windows PC. On macOS 10.14 or earlier, or on a PC without the Apple Devices app, use iTunes instead.
- Select the iPhone in the sidebar. Click Trust on the computer, tap Trust on the iPhone and enter your passcode if asked.
- Click Restore iPhone and follow the onscreen instructions.
- Review the terms and conditions and click Agree.
The Hello screen appears when the restore is done. One difference from the Settings method: Apple says restoring an iPhone with a computer doesn't delete your eSIM. If you only want the latest iOS without erasing anything, see our guide on how to update iPhone instead.
How to factory reset iPhone without the passcode
Apple's only way back into an iPhone after a forgotten passcode is to erase it, unless you recently changed the passcode. Apple suggests trying these in order.
1. Passcode Reset, if you changed it in the last 72 hours
On iOS 17 and later, Apple says you can still use your previous passcode for 72 hours after changing it. After 5 wrong attempts, tap Forgot Passcode? on the iPhone Unavailable screen, tap Enter Previous Passcode and set a new one. Nothing is erased.
2. Reset from the Lock Screen
This works on iOS 15.2 or later, with Find My turned on, a Wi-Fi or cellular connection and your Apple Account password. On iOS 17 or later:
- Keep entering a passcode until the iPhone Unavailable screen appears.
- Tap Forgot Passcode?
- On the Security Lockout screen, tap Start iPhone Reset.
- Enter your Apple Account password to sign out.
- Tap Erase iPhone. With an eSIM, you can choose to keep it or delete it.
On iOS 15.2 and iOS 16, Apple says you'll see an Erase iPhone option instead of Forgot Passcode? If you use an eSIM on iOS 16 or earlier, Apple says to ask your carrier for a QR code to set it up again before you start.
3. Recovery mode with a computer
If neither option appears, Apple's last route is recovery mode. You need a Mac or Windows PC, a cable that can charge the phone, an internet connection and up to 60 minutes. For an iPhone with Face ID:
- Turn the iPhone off: press and hold the side button and the volume down button until the power off slider appears, then drag it. On an iPhone with a Home button, hold the top or side button instead.
- Connect the cable to the computer. Then connect it to the iPhone and quickly press and hold the side button.
- Keep holding the side button through the Apple logo. Let go when you see an image of a computer and a cable.
- On a Mac, select the iPhone in the Finder and choose Restore when offered Restore or Update. On a PC, open Apple Devices, select the iPhone, select General, then Restore.
iPhone 8, iPhone 8 Plus and iPhone SE (2nd and 3rd generation) use the side button too. On iPhone 7 and iPhone 7 Plus, hold the volume down button instead. On iPhone 6s and earlier and iPhone SE (1st generation), hold the Home button.
Apple notes the download can take more than 15 minutes. If the phone leaves recovery mode during the download, let the download finish, turn the iPhone off and start recovery mode again.
How to erase an iPhone remotely
If the phone is lost or stolen, you can erase it from icloud.com/find. Sign in, select the iPhone, select Erase This Device and follow the onscreen instructions. You can also do this in the Find My app on another device signed in to the same Apple Account.
Apple says an offline iPhone is erased the next time it comes online, and you can cancel with Stop Erase Request until then. Unlike an erase in Settings, a remote erase leaves Activation Lock on, so the phone still needs your Apple Account and password to be reactivated. If you don't expect to get the phone back, Apple suggests asking your carrier to suspend service.
How to factory reset iPhone before you sell it
Apple's checklist for selling, giving away or trading in an iPhone adds a few steps to the erase. If you're trading it in, check Parts and Service History first: Apple says a part marked Finish Repair has to be finished before the trade-in.
- Back up the iPhone and move your data to the new phone.
- Unpair any Apple Watch and cancel or transfer your AppleCare plan.
- Sign out. On iOS 26 or later, open Settings, tap your name, tap Sign Out and choose Erase this iPhone or Sign Out But Don't Erase.
- If you're moving to an Android phone, deregister iMessage.
- Erase the phone with Erase All Content and Settings. If it uses an eSIM, Apple says to erase the eSIM too when asked.
- Remove the old iPhone from your Apple Account's list of trusted devices.
Apple says erasing the phone this way turns off Find My and Activation Lock. That matters to the buyer: on iOS 15 or later, a phone still protected by Activation Lock shows an "iPhone Locked to Owner" screen, and Apple tells buyers not to take it. A phone is ready for its new owner when it shows the Hello screen.
No longer have the phone? If you gave it away, Apple says to ask the new owner to erase it. If it's lost or stolen, erase it from iCloud.com. Either way, remove it from your trusted devices, change your Apple Account password and turn on two-factor authentication.
Reset settings without erasing your iPhone
Go to Settings, tap General, tap Transfer or Reset iPhone, then tap Reset (not Erase All Content and Settings). Apple's options include these:
| Option | What it does, per Apple |
|---|---|
| Reset All Settings | Returns all settings to their defaults, including network, keyboard dictionary, location and privacy settings, and removes Apple Pay cards. No data or media are deleted. |
| Reset Network Settings | Removes network settings, including previously used networks and VPN settings not installed by a configuration profile or MDM. It also renames the device "iPhone" and makes manually trusted certificates untrusted. |
| Delete All eSIMs | Deletes every eSIM on the phone. You'll need a new eSIM or a physical SIM to connect. |
| Reset Keyboard Dictionary | Erases only the words you've added. |
| Reset Home Screen Layout | Puts built-in apps back in their original layout. |
| Reset Location & Privacy | Returns location services and privacy settings to their defaults. |
Apple suggests backing up before you reset settings, so you can restore your old ones if the reset doesn't fix the problem. For freeing up storage, see our guide on how to clear cache on iPhone.
After the reset: set up or restore
When the Hello screen appears, follow the setup steps. To bring your data back from iCloud, tap From iCloud Backup on the Transfer Your Apps & Data screen, sign in and choose the most recent backup. Keep the phone on Wi-Fi and power until the progress bar finishes. Apple says photos, music and apps keep downloading from iCloud after setup.
Frequently asked questions
Does a factory reset delete everything on an iPhone?
It deletes everything on the phone, including photos, contacts, apps and Apple Pay cards. Apple says your content won't be deleted from iCloud, and you can restore the phone's data from a backup during setup.
How do I factory reset an iPhone with buttons?
The method that uses the buttons is recovery mode: you hold a button while connecting the iPhone to a Mac or PC, then restore it from the computer. The button for each model is in the recovery mode section above.
What is a hard reset on iPhone?
If you want to restart a frozen iPhone without erasing it, use what Apple calls a force restart. Apple suggests it when an iPhone isn't responding and can't be turned off and back on. Apple's iPhone User Guide gives these steps: press and quickly release the volume up button, press and quickly release the volume down button, then press and hold the side button until the Apple logo appears. It's a restart, not one of Apple's erase methods.
Does a factory reset remove Find My?
An erase in Settings turns off Find My and Activation Lock, according to Apple. A remote erase from iCloud.com is different: Activation Lock stays on, so only the owner's Apple Account password can reactivate the phone.
Does a factory reset remove the eSIM on iPhone?
With the Settings erase, you choose: it asks whether to keep or delete the eSIM. Restoring with a computer doesn't delete it, according to Apple. The Lock Screen reset on iOS 17 or later also lets you keep or delete it.
More in Phones & Gadgets
- How to block spam calls on iPhone, from Call Screening to carrier filters
- How to clear cache on iPhone in Safari, Chrome and other apps
- How to scan documents on iPhone with Notes, Files or Preview
- How to screen record on iPhone, with or without sound
- How to transfer photos from Android to PC with a cable or wirelessly