Forgot your iPhone or iPad passcode? Here’s how to reset it

If you have forgotten the main passcode of your iPhone, iPad, or iPod touch, this tutorial will help you reset it successfully.

First, we’ll try to back up even your disabled or locked iPhone or iPad. This will ensure all your data is safe.

And if you can’t back up your data on your locked iPhone for any reason, all is not lost. You should be able to get back most of your important data, such as contacts, messages, calendar events, apps, etc.

Reset forgotten iPhone passcode

Some things to consider

iPhone is disabled

After entering the wrong passcode five times in a row, your iPhone is locked and disabled. It prevents you from trying any other passcode for a specific duration and shows the iPhone Unavailable/iPad Unavailable message on the screen. It can display try again in 1 minute, try again in 15 minutes, try again in 1 hour, or try again in an absurdly long time.

iPhone is disabled for 1 minute and iPhone Unavailable try again after 1 hour message on screen

Can I reset my iPhone passcode using my Apple ID?

You can’t use your Apple ID password to reset your forgotten iPhone password, but you can log in to using your Apple ID to erase your iPhone and set it up again. However, the downside of this is that all your iPhone data and settings will be erased.

Then how can I get into my iPhone if I forgot the password?

The only way to completely erase and reset your iPhone. There is no other way.

Will I lose all my iPhone data?

You’ll lose all data on your iPhone or iPad unless they are backed up to a computer or iCloud, in which case, you can easily restore it.

Can I reset a forgotten iPhone or iPad passcode without losing data?

As mentioned, the only way to regain access to your iPhone is to erase it. If you backed up your device to iCloud or to a computer, you will be able to recover that data. If you didn’t back up your device, most data could be lost. Unless…

Try to back up your locked iPhone or iPad data

If you ever backed up your iPhone to your computer (or even remember connecting it to your computer), you could be in luck.

When you connect an iPhone or iPad to a Mac or PC for the first time, your device will ask you to confirm that you trust the computer. Once that’s done, your iPhone remembers that it can trust this computer.

So, try to remember if you trusted any Mac or PC with your iPhone. It would most likely be your own computer, or a family member’s computer. If you know you previously connected your iPhone to your computer, you should be able to back it up following these steps:

  1. Connect your iPhone to the computer.
  2. Open Finder on Mac or open iTunes on Windows PC.
  3. In Finder, select your iPhone from the left sidebar. In iTunes, click the tiny iPhone logo from the top of the window.
  4. From the General section, click Back Up Now.
Back up iPhone to Mac using Finder

This will back up your locked or disabled iPhone. Most of your data can now be restored after resetting the forgotten iPhone passcode.

Can’t back up?

If you are asked to Trust the computer or asked for the iPhone passcode when connecting it to your computer, it means that your iPhone was never connected to this computer to begin with. In which case, you will not be able to back it up and will lost most of your data.

Still, there is hope!

Is everything lost if I can’t back up my locked iPhone?

Any data that is not stored on iCloud or on a third-party service will essentially be lost. But if like most people you at least sync some of your data (ie. contacts, photos, reminders, etc…) with a cloud service such as iCloud or Google Drive, you will be able to regain access to this data.

Apps using iCloud on iPhone
Contacts, Notes, etc., are saved in iCloud and will sync back after erasing your iPhone and setting it again.

6 ways to reset a forgotten iPhone or iPad passcode

1. Reset your iPhone passcode straight from your iPhone

It’s possible to reset and erase a passcode-locked iPhone or iPad without needing to connect to a computer. When your device is in what Apple calls Security Lockout mode, after too many incorrect passcode attempts, just enter your Apple ID and password to erase it.

iPhone device screenshot with the "iPhone Unavailable" message on the lock screen and the "Erase iPhone" option in the bottom right, set against a vivid gradient background
Erase iPhone appears after several incorrect passcode attempts.
  1. On the lock screen of your iPhone, make several incorrect passcode attempts until a warning message appears, asking you to try again later.
  2. Keep entering the wrong passcode until you see the Erase iPhone option appear in the bottom corner of the screen.
  3. Tap Erase iPhone, then hit Erase iPhone again to confirm the action.
  4. Enter your Apple ID password. This will sign you out of your Apple ID on this iPhone.
  5. Finally, select Erase iPhone to permanently delete all of your data and settings.
Three iPhone device screenshots showing the Security Lockout process when erasing iPhone, set against a vivid gradient background
Security Lockout lets you erase your iPhone without using a computer.

Now your iPhone will restart and launch into the usual iOS setup procedure you previously went through after unboxing your iPhone. Simply follow the onscreen instructions to set up your iPhone again, restore data and settings from a backup and create a new passcode—one you won’t forget in the future.

2. Get into Recovery Mode using Finder on Mac

Note: If you don’t have a Mac, borrow one from a friend or family. If that’s not possible, visit your nearest Apple Store and ask them for help. They will oblige.

1) Make sure your iPhone or iPad is not plugged into the Mac.

2) Turn off your iPhone or iPad.

3) Plug one end of the cable into your iPhone or iPad. Don’t plug the other end into the Mac’s USB port yet (you have to do that in the next step).

4) Press & hold the Power button on your iPhone or iPad and immediately plug the other end of the cable into your Mac. Keep holding the button on your iPhone or iPad until you see the recovery mode screen (a black screen with a white cable pointing toward a MacBook).

Recovery mode screen on iPhone
Recovery mode screen.

Note: After following the above steps, if you don’t get the recovery mode screen but see the passcode screen on your iPhone or iPad, turn off your device and follow the above steps again.

5) Locate your iPhone or iPad in Finder by clicking your device name or the general ‘iPhone‘ or ‘iPad‘ name in the left sidebar.

6) You’ll now see a popup alert in Finder on Mac. Click the Restore button here.

Restore iPhone using Finder on Mac

Your Mac will download the entire iOS operating system and install a fresh copy on your iPhone or iPad whose passcode you have forgotten.

3. Using iTunes on Windows PC

The steps to restore an iPhone or iPad (whose passcode you have forgotten) using a Windows PC are exactly the same as Finder on Mac.

The only difference is you’ll have to use iTunes (instead of Finder). And in Finder, you’re asked to locate your iPhone from its left sidebar. But in iTunes, you have to click the iPhone icon from the top. Besides that, everything is the same.

Click the tiny iPhone icon in iTunes

4. Restore backup if ‘Find My’ was turned off

Find My service is a security feature that is switched on by default. But if you’re among the few who had turned it off, then you can follow these steps to reset your iPhone passcode by restoring a previously made backup on your computer:


  • Find My iPhone or Find My iPad must be off.
  • A trusted Mac or PC where you had backed up this iPhone or iPad.
  • An old iPhone or iPad backup on that Mac or PC.
  • Appropriate cable.

1) Connect your iPhone or iPad to a trusted Mac or PC using a cable.

2) Select your iPhone or iPad in Finder or iTunes.

3) Click Restore Backup.

Restore Backup using Finder on Mac

4) Select an old backup and click Restore.

Choose an old backup file and click Restore

5) Finally, click Erase and Restore.

Erase and Restore iPad in Finder on Mac

After this, you can set up your iPhone and create a new passcode.

But as mentioned, the above steps will only work if Find My iPhone was turned off on this device. In case it wasn’t, you’ll have to follow the previous methods of using Recovery mode or use the remaining methods below.

Find My must be turned off before iPhone or iPad can be restored

5. Reset iPhone passcode using iCloud on a computer

1) Go to in a web browser, click Sign in, and use your Apple ID to log in.

2) Click Find My.

Find My on iCloud web

3) Click All Devices from the top and select your iPhone.

Select your iPhone on iCloud web

4) Click Erase iPhone > Erase.

Erase iPhone using iCloud web

Your iPhone will be erased remotely.

6. Use third-party tools

When you do a web search on Google, Bing, Yahoo, etc., you’ll find several iPhone unlocker tools that claim to recover your forgotten iPhone passcode and give you instructions for that.

These are unofficial, and in most cases, they won’t work. Plus, they may do more harm than good and will work only if Find My iPhone was off (which, for almost 99% of iPhone users, is switched on). So, it’s best to avoid downloading them to your Mac or PC.

What to do after you erase your iPhone

Once you have erased your disabled iPhone or iPad, you get to the setup screen. This process is the same as when you turn on your new iPhone for the first time. But there is a major change: you may have to enter your Apple ID password on one of the setup screens to bypass the Activation Lock.

Next, you can set up your iPhone as a new device or restore a backup from a computer or iCloud.

Related tips:

Some images used in this post are from Apple.