Why is iPhone asking for passcode after factory reset? How to fix it

An iPhone asks for a passcode after a factory reset because Activation Lock is still on, and it wants the passcode or Apple Account password that was used on the phone before the erase.

This guide explains each passcode prompt you can see around Erase All Content and Settings, how to get past it, and what to do if you never knew the old passcode.

Why is iPhone asking for passcode after factory reset? How to fix it
In recovery mode, choose Restore rather than Update to erase an iPhone whose passcode you no longer know. (Image: Apple)

How to get past the passcode screen after resetting an iPhone

Find My links the phone to an Apple Account, and that link survives an erase. Each time the iPhone is activated, it checks with Apple whether Activation Lock is on.

  1. Turn on the iPhone and follow setup until the Activation Lock or iPhone Locked to Owner screen appears.
  2. Choose the option to unlock with the device passcode, if it is offered.
  3. Enter the passcode the iPhone used before it was erased.
  4. Or choose the Apple Account option and enter the Apple Account email and password used to set up the phone.
  5. Continue setup until the Home Screen appears.

Which passcode is iPhone asking for after erase?

The phone can ask for a passcode at three points. Match the screen you see to the passcode it wants.

When you see the prompt What it wants Why
Right after tapping Erase All Content and Settings The current device passcode, or a Restrictions or Screen Time passcode Confirms the owner is the one erasing the phone
After the erase, during setup (Activation Lock) The old device passcode or the Apple Account password Find My was still on, so the phone is linked to that account
During setup, on a used iPhone you bought The previous owner's Apple Account details The seller did not remove the phone from their account

Forgot old iPhone passcode after factory reset

Your situation What to do
You remember the Apple Account password Choose the Apple Account option on the Activation Lock screen and sign in
You forgot the Apple Account password Reset the Apple Account password, then sign in on the lock screen
You do not remember your Apple Account Try the email address or phone number you use most with Apple services
You still own the account and the phone is offline Remove the device at icloud.com/find
You bought it used Ask the seller to enter their password or remove it from their account
None of the above works and you have proof of purchase Start an Activation Lock support request with Apple
The phone belongs to a business or school Contact the IT department or manager

Remove Activation Lock from iCloud.com

Use this when the account is yours but the passcode screen still blocks setup. Apple notes that for iPhone this may work even when the phone is not offline.

  1. Go to icloud.com/find in a browser on another device.
  2. Sign in with the Apple Account that was used on the iPhone.
  3. Select the iPhone in the device list.
  4. Click Remove This Device.
  5. Restart the iPhone and go through setup again.

Why is my new iPhone asking for a passcode it never had?

On a second-hand iPhone with iOS 15 or later, an iPhone Locked to Owner screen means the phone is still protected by the previous owner's Activation Lock. Apple advises against taking ownership of such a phone.

  1. Hand the iPhone back to the seller and ask them to enter their Apple Account password.
  2. If the seller is not there, ask them to remove the device from their account in a browser.
  3. Restart setup once they confirm it is removed.
  4. Check that the Hello screen appears, which means the phone is ready for you.

How to erase an iPhone so it does not ask for a passcode

Signing out of the Apple Account before erasing removes Activation Lock, so the next owner never sees the prompt.

  1. Back up the iPhone.
  2. Open Settings, tap your name, scroll down and tap Sign Out.
  3. On iOS 26 or later, choose Erase this iPhone or Sign Out But Don't Erase; on iOS 18 or earlier, enter your Apple Account password and tap Turn Off.
  4. Go to Settings > General > Transfer or Reset iPhone and tap Erase All Content and Settings.
  5. Enter your device passcode or Restrictions passcode if asked.
  6. Tap Erase iPhone.
Erase iPhone without passcode prompt using the Erase This iPhone screen
The erase summary lists Find My and Activation Lock, which are removed along with your Apple Account sign-in. (Image: Apple)

How to know the iPhone is no longer locked

  1. Turn on the iPhone after the erase.
  2. Confirm the Hello screen appears instead of iPhone Locked to Owner.
  3. Start setup and check that no previous Apple Account details are requested.
  4. Sign in with your own Apple Account when setup asks.

iPhone passcode not working after reset

iPhone is not recognizing the passcode at Activation Lock

The screen wants the passcode the phone used before the erase, not a new one.

  1. Enter the last passcode that unlocked this iPhone before it was erased.
  2. Switch to the Apple Account option if that passcode does not work.
  3. Reset the Apple Account password if you cannot sign in.

Forgot the passcode before you could erase the iPhone

Erase All Content and Settings needs the current passcode.

  1. Turn off the iPhone and connect it to a Mac or Windows PC.
  2. Hold the side button (Face ID models) until the recovery mode screen with a computer and cable appears.
  3. Select the iPhone in Finder on a Mac, or in Apple Devices on Windows.
  4. Select Restore and follow the prompts.
  5. Expect Activation Lock afterwards, and sign in with your Apple Account.

Activation Lock screen on a phone you cannot unlock at all

The linked Apple Account cannot be accessed.

  1. Collect your proof of purchase.
  2. Start an Activation Lock support request with Apple.

iPhone asking for passcode after reset FAQ

Why is my iPhone asking for a passcode after a reset?

Activation Lock is still on. Find My links the iPhone to an Apple Account, and the link survives Erase All Content and Settings. Enter the old device passcode or the Apple Account password to continue setup.

Why is my iPhone asking for the old passcode?

The Activation Lock screen accepts the passcode the phone used before it was erased, as proof that the owner is setting it up again. A new passcode does not exist yet, so only the old one or the Apple Account password works.

Why is my new iPhone asking for a passcode?

A used iPhone that asks for a passcode or the previous owner's account is still linked to that owner. Ask the seller to enter their password or remove the device from their account before you take it.

Why does my iPhone passcode not work after reset?

Erasing removes the passcode from the phone, but Activation Lock asks for the previous one. If you set a different passcode recently, use the latest one, or sign in with the Apple Account instead.

How do you remove Activation Lock without the passcode?

Sign in with the Apple Account email and password on the Activation Lock screen, or remove the iPhone at icloud.com/find. If you have no account access but have proof of purchase, start an Activation Lock support request.

Does a factory reset remove Activation Lock?

No. Activation Lock stays on after an erase while Find My was on. Sign out of your Apple Account before erasing, or remove the device from your account, to turn it off.

Do I need a passcode on iPhone to erase it?

Yes, if a passcode is set. Erase All Content and Settings asks for the device passcode, or a Restrictions passcode, before it erases. Without it, reset the iPhone with a computer in recovery mode.

Can you set up an iPhone without the old passcode?

Yes, if you can sign in with the Apple Account that owns the iPhone or remove it at icloud.com/find; otherwise only the owner or an Apple support request can release it. Activation Lock is designed to block anyone except the owner from reactivating an erased iPhone, so no reset method bypasses it.

Philip Celasco

Philip is a Texas-based technology writer and IT administrator at Techdows.com with more than 10 years of experience creating practical content for everyday users and professionals. He specializes in web browsers, particularly Chromium-based platforms such as Google Chrome, Microsoft Edge, Brave, and Opera. Through his work as an IT administrator, Philip has hands-on experience managing devices, configuring browser policies, troubleshooting software and network issues, and helping people resolve problems that affect productivity and security. His articles are based on practical testing and real-world technical experience. He covers browser settings, extensions, performance problems, privacy controls, security features, and Windows troubleshooting. Outside work, Philip enjoys the quieter side of life in Texas and stepping away from the screen when he can. He has two kids, two cats and loves to play golf with his mother during the weekends.

Leave a Reply

Your email address will not be published. Required fields are marked *