What to Do If You Forgot Your iPhone Passcode

If you forget your iPhone passcode, there is no legitimate setting that simply reveals it. Apple’s recovery process is designed to protect the encrypted data on the phone, so regaining use of the device can require resetting it and then restoring your data from a backup.

Use Apple’s passcode recovery options

If you forgot the iPhone passcode, repeated guessing can increase the lockout period. Depending on the iOS version and how recently the passcode changed, the lock screen may offer a supported recovery option. Otherwise, regaining access generally requires erasing the iPhone and setting it up again, then restoring from an available backup. A Mac uses Finder and a current Windows PC uses Apple Devices for recovery mode. Erasing the device does not remove Activation Lock or eliminate the need for the associated Apple Account.

Stop repeatedly guessing

After incorrect attempts, the iPhone can impose waiting periods or become unavailable for longer intervals. If you do not know the code, random guessing is unlikely to help and can make recovery slower.

Look for an on-device recovery option

Recent iOS versions can show recovery or reset options on the unavailable/lock screen in supported circumstances. Follow the prompts carefully. You will generally need the Apple Account credentials associated with the device and a network connection.

If you changed the passcode recently, some iOS versions provide a limited period in which the previous passcode can help you regain access and set a new one. Availability depends on the software version and circumstances.

Reset the iPhone with a computer when necessary

If on-device recovery is unavailable, Apple’s official process can use recovery mode with a Mac or Windows PC. A current Windows PC uses Apple Devices; a Mac uses Finder. The process can erase the iPhone so it can be set up again.

Restore your data afterward

After the reset, sign in with the Apple Account associated with the iPhone and restore from an available iCloud or computer backup. Data that was synchronized separately through iCloud may return after you sign in and syncing completes.

Activation Lock still protects the phone

Erasing an iPhone does not make a stolen device freely usable. Activation Lock can require the Apple Account that was previously associated with the phone. Avoid websites or tools that claim they can legitimately bypass another person’s passcode or Activation Lock.

Prepare for next time

Keep current backups, make sure your trusted phone numbers and account-recovery information are up to date, and store important account credentials securely. Those steps make a forgotten passcode much less disruptive.

What if you do not have a backup?

If the recovery method requires erasing the iPhone and the data was not backed up or synchronized elsewhere, that local data may be lost. This is a consequence of the security design: a forgotten passcode cannot simply be bypassed to read encrypted information. Check iCloud and other cloud services from another trusted device to see what data is already synchronized before resetting.

Avoid paid “unlock” scams

Be skeptical of software or websites that promise to remove a passcode without erasing data, defeat Activation Lock, or unlock a device belonging to someone else. Use Apple’s documented recovery methods and proof-of-purchase support channels when ownership verification is required.