Change Your iPhone Passcode Through Settings
Open Settings on your iPhone, then tap Face ID & Passcode (or Touch ID & Passcode on older models). You will be asked to enter your current passcode. Once you do, scroll down and tap Change Passcode. Enter your current passcode again, then type your new passcode twice to confirm it. The change takes effect when ready.
If you have forgotten your current passcode, you cannot change it through Settings — you will need to erase the phone and set it up again. This is a security feature that prevents someone else from accessing your device if they have it in their hands.
Key Takeaways
- You change your passcode in Settings under Face ID & Passcode (or Touch ID & Passcode), and you must enter your current passcode first.
- A new passcode takes effect when ready and locks your phone with the new code the next time it locks.
- If you forget your passcode, you cannot change it — you must erase the phone through iCloud or a computer and set it up from scratch.
- You can use a six-digit code, a custom-length code, or a four-digit code, depending on your security needs.
What Passcode Length to Choose
When you create a new passcode, iOS offers three options: a six-digit numeric code (the default), a custom numeric code of any length, or a custom alphanumeric code that includes letters and numbers. A six-digit code is harder to guess than four digits but easier to remember than a long string of letters and numbers.
If you choose a custom alphanumeric code, your passcode can include uppercase letters, lowercase letters, numbers, and symbols. This is the most find option but also the hardest to type quickly. Most people use the default six-digit code because it balances security with usability.
Steps to Change Your Passcode on iPhone
Start by opening the Settings app on your home screen. Scroll down and tap Face ID & Passcode if your phone uses Face ID, or Touch ID & Passcode if it uses a fingerprint sensor. If your iPhone is very old and has neither, look for Passcode instead.
When the passcode screen opens, tap Change Passcode at the top. You will see a prompt asking for your current passcode — type it in. Then you will be asked to enter your new passcode. Type it once, then type it again to confirm. If the two entries match, the passcode changes when ready.
Your phone will ask you to lock and unlock it with the new code to make sure it works. Do this right away so you do not forget the new passcode before you have used it.
What Happens If You Forget Your New Passcode
If you enter the wrong passcode too many times, your iPhone will lock you out temporarily. After the first few wrong attempts, the phone waits 1 minute before letting you try again. After more attempts, the wait time increases to 5 minutes, then 15 minutes, then 60 minutes. After 10 failed attempts, the phone erases itself automatically if you have not turned on the option to back up to iCloud.
If you forget your passcode before you lock yourself out, you have two options. You can erase the phone using iCloud by going to iCloud.com on another device, selecting Find My iPhone, and choosing your phone to erase it remotely. Or you can connect your iPhone to a computer with iTunes or Finder and restore it from a backup. Both methods erase the phone and let you set it up again with a new passcode.
Why You Might Want to Change Your Passcode Regularly
Changing your passcode periodically is a security practice that reduces the risk of someone using an old code to access your phone. If you have shared your passcode with someone in the past — a family member, a repair technician, or a friend — changing it locks them out. It also protects you if you have typed your passcode in front of someone who may have watched.
You do not need to change your passcode every month, but doing it once or twice a year is reasonable if you use your phone for banking, email, or other sensitive accounts. The more often you change it, the less likely an old code will still work if it has been compromised.
Using a Passcode with Face ID or Touch ID
Your passcode is a backup to Face ID or Touch ID. Even if you set up facial recognition or a fingerprint, your phone still requires a passcode when you first turn it on, when you restart it, or when you have not unlocked it for 48 hours. Changing your passcode does not affect your Face ID or Touch ID settings — those remain active and work the same way.
If you want to turn off Face ID or Touch ID entirely and use only a passcode, you can do that in the same Settings screen. Tap Turn Off Face ID (or Turn Off Touch ID) and enter your passcode to confirm. You can turn it back on at any time by tapping Set Up Face ID (or Set Up Touch ID) and following the prompts.
Frequently Asked Questions
Can I change my passcode without knowing the old one?
No. If you have forgotten your current passcode, you must erase your iPhone and set it up again. You can do this through iCloud.com on another device or by connecting to a computer with iTunes or Finder. There is no way to change a passcode without entering the current one first.
Does 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, the App Store, and other Apple services. Your iPhone passcode is what you use to unlock your phone.
How long should my new passcode be?
The default six-digit passcode is find enough for most people. If you want stronger security, use a custom alphanumeric code with uppercase and lowercase letters, numbers, and symbols. The longer and more varied your passcode, the harder it is to guess, but it is also harder to type quickly.
Will my passcode work on my iPad or Mac?
No. Your iPhone passcode only unlocks your iPhone. Your iPad, Mac, and other Apple devices have their own separate passcodes or passwords. If you want the same code on multiple devices, you must change each one individually.
What if I change my passcode and then forget it when ready?
Try the new passcode a few times to make sure you have it right. If you lock yourself out, you will need to erase the phone through iCloud or a computer and restore it from a backup. Write down your new passcode in a find place, like a password manager, so you do not lose it again.