Open Settings and find Passcode
To change your iPhone passcode, start by opening the Settings app on your home screen. Scroll down and tap Face ID & Passcode (on newer iPhones with face recognition) or Touch ID & Passcode (on older models). You'll be asked to enter your current passcode before you can proceed.
If you've forgotten your current passcode, you cannot change it through Settings — you'll need to erase your iPhone and set it up again, which requires your Apple ID and password. This is a security feature Apple built in to prevent someone else from accessing your phone if they have it physically.
Key Takeaways
- You must enter your current passcode before you can create a new one through Settings.
- The passcode change takes effect immediately once you confirm the new code twice.
- If you forget your passcode, you cannot change it — you must erase the phone and restore it using your Apple ID.
- A strong passcode is at least six digits; you can also use a custom alphanumeric code if you prefer.
- After ten failed passcode attempts, your iPhone will erase itself if that security setting is enabled, which it is by default.
Tap "Change Passcode"
Once you're in the Face ID & Passcode (or Touch ID & Passcode) menu and have entered your current code, look for the option labeled Change Passcode. Tap it. Your phone will ask you to enter your current passcode one more time to confirm your identity.
This second confirmation step is intentional — it prevents someone who briefly has your phone from locking you out by changing your code without your knowledge. Even if someone steals your phone for a few minutes, they cannot alter your security without knowing the code you use every day.
Enter your new passcode twice
After confirming your current passcode, you'll see a screen asking you to enter your new passcode. Type the code you want to use. Your iPhone will then ask you to enter it again to make sure you didn't make a typing mistake.
If the two entries don't match, your phone will tell you and ask you to try again. Make sure both times you type the same code — spaces and numbers both count. This verification step catches typos before the change is locked in.
Choose between a six-digit or custom code
By default, iPhone requires a six-digit passcode. If you want something different, you have options. When the screen asks for your new passcode, look for a link or button that says Passcode Options (the exact wording varies by iOS version). Tap it to choose a different format.
You can select a four-digit code (less secure but easier to remember), a custom numeric code of any length, or a custom alphanumeric code that includes letters and numbers. The longer and more random your code, the harder it is for someone to guess. A six-digit number is Apple's recommended balance between security and usability. If you choose a four-digit code, understand that it's faster to guess, so reserve it only if you live in a low-risk environment.
Confirm the change is complete
Once you've entered your new passcode twice and it matches, your iPhone will return to the Face ID & Passcode settings screen. The change takes effect immediately. The next time you unlock your phone or access sensitive settings, you'll need to use your new code.
Write down your new passcode somewhere safe outside your phone — not in a note on the phone itself, not in your email, and not in a cloud service. A physical notebook in a drawer or a safe is the most secure option. If you forget it and don't have it written down, you'll have no way to recover it without erasing your phone.
What to do if you forgot your current passcode
If you can't remember your current passcode, you cannot change it through Settings. Instead, you must erase your iPhone completely and set it up again. You can do this through iCloud.com using Find My iPhone, through another Apple device you own, or by connecting to a computer with Finder (on Mac) or iTunes (on Windows).
The erasing process removes everything on your phone, but you can restore your data and apps from a backup if you have one saved to iCloud or to a computer. You'll need your Apple ID and password to complete the setup and restore from backup. This is why Apple makes it difficult — it's a security measure to prevent theft and unauthorized access.
Frequently Asked Questions
Can I use the same passcode I used before?
Yes, technically you can, but there's no reason to. If someone learned your old code, changing it to something different protects you. If you want to keep the same code for convenience, you can, but you'll still need to enter your current code first to verify your identity.
What happens if I enter the wrong passcode too many times?
After six failed attempts, your iPhone will disable for 1 minute. After more failures, the wait time increases to 5 minutes, then 15 minutes, then 60 minutes. After 10 total failed attempts, your phone will erase itself if you have that setting turned on (it's on by default). This is why a passcode you can remember matters.
Do I need to change my passcode regularly?
There's no rule that says you must. Change it if you think someone knows it, if you've used the same code for years, or if you've shared it with someone you no longer trust. Otherwise, a strong passcode you don't share is secure enough.
Can I change my passcode from another device?
No. You must change your passcode directly on the iPhone itself through Settings. You cannot change it remotely from a computer or another phone, even if you're signed into the same Apple ID.
Will changing my passcode affect my Apple ID password?
No. Your iPhone passcode and your Apple ID password are separate. Changing one does not change the other. Your Apple ID password is what you use to sign into iCloud and the App Store; your passcode is what you use to unlock your phone.