To change your iPhone passcode, open Settings, tap Face ID & Passcode or Touch ID & Passcode, and authenticate with your current passcode. Tap Change Passcode, enter your new code, and enter it again to confirm.
Change your passcode in Settings
- Open Settings.
- Tap Face ID & Passcode or Touch ID & Passcode. On some older iPhones without Touch ID, tap Passcode.
- Enter your current iPhone passcode when prompted. You may be asked to enter it again before continuing.
- Tap Change Passcode.
- Enter your new passcode. To use a different format, tap Passcode Options when prompted.
- Enter the new passcode again to confirm.
Choose a passcode format
A six-digit numeric code is the usual default. When you tap Passcode Options, your iPhone may offer these alternatives:
| Option | What it allows |
|---|---|
| Four-Digit Numeric Code | A four-digit number. |
| Custom Numeric Code | A numeric code with a length you choose. |
| Custom Alphanumeric Code | A code made with letters and numbers. |
Apple identifies Custom Numeric Code and Custom Alphanumeric Code as its most secure options. In general, a longer, unique code is harder to guess than a short or predictable one. Available choices may be limited by device-management rules.
What to know before changing your passcode
- Your iPhone passcode is different from your Apple Account password. Changing one does not change the other.
- You need to know your current device passcode to change it through Settings. Face ID or Touch ID may be used for some authentication, but don’t assume biometrics replace the current passcode in this process.
- A work- or school-managed iPhone may require a minimum passcode length or an alphanumeric code. If your new code is rejected, check with your organization’s administrator.
How Stolen Device Protection can affect the change
If Stolen Device Protection is enabled, changing your passcode may require Face ID or Touch ID and a one-hour Security Delay, followed by another biometric authentication. Whether the delay applies depends on whether your iPhone is at a familiar location and whether the feature is set to require the delay Always.
If you forgot the passcode you just changed
On iOS 17 or later, you may be able to use your previous passcode within 72 hours of changing it:
- After five incorrect attempts, wait for the iPhone Unavailable screen.
- Tap Forgot Passcode?, then tap Enter Previous Passcode.
- Follow the prompts to set a new passcode.
This recovery option requires the iPhone to be signed in to your Apple Account, connected to Wi-Fi or cellular, and have Find My turned on. Using the previous passcode prompts you to change the passcode again immediately.
To end the 72-hour window sooner, go to Settings > Face ID & Passcode or Settings > Touch ID & Passcode, authenticate, and tap Expire Previous Passcode Now.
If you don’t know your current passcode
You can’t change your passcode through the normal Settings steps without knowing the current code. If Passcode Reset with your previous passcode isn’t available, Apple’s recovery process requires you to erase the iPhone and set it up again. This deletes the device’s data and settings; you can restore from a backup if you have one.
Choose and protect your new passcode
- Choose a code you can remember but that others are unlikely to guess. Avoid obvious sequences, repeated digits, and personal dates.
- If someone else may know your old passcode, change it and consider whether they could also access your Face ID or Touch ID.
- If you’re concerned someone could use your previous passcode for recovery, use Expire Previous Passcode Now on iOS 17 or later rather than leaving it available during the 72-hour window.
- Face ID and Touch ID do not replace your passcode entirely. Your iPhone may still require the passcode after a restart or when you access passcode settings.