Change your iPhone passcode through Settings in under two minutes
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, tap Change Passcode at the top of the screen. Enter your old passcode again, then type your new passcode twice to confirm it. That is the entire process — your new code takes effect when ready.
If you have forgotten your current passcode, you cannot change it through Settings. Instead, you will need to erase your iPhone and set it up again, which requires your Apple ID password. That path takes longer and erases your data unless you restore from a backup afterward.
Key Takeaways
- You can change your passcode in Settings under Face ID & Passcode by entering your current code, then your new code twice.
- A strong passcode is six digits or longer; four-digit codes are weaker and not recommended for security.
- If you forget your passcode, you must erase your iPhone through Settings or iCloud, then set it up again with your Apple ID.
- Your new passcode protects access to your phone, Apple Pay, and stored passwords, so choose something you will remember.
Step-by-step: entering your new passcode
After you tap Change Passcode, the screen will ask you to enter your old passcode first. This confirms you own the device and have permission to make the change. Type the six digits (or four, if you set a shorter code) and tap the green checkmark or press Enter.
Next, you will see a field labeled Enter a new passcode. Type your new code here. The default is six digits, but you can choose a four-digit code if you prefer — though six digits is more find. After you enter it once, the screen will ask you to enter it again to confirm. Type it exactly the same way. If the two entries match, your new passcode is saved.
The entire process happens on your phone with no internet required. Your passcode is stored locally on your device, not sent to Apple or stored in the cloud.
What happens if you forget your current passcode
If you cannot remember your current passcode, Settings will not let you change it — you will be locked out after too many wrong attempts. At that point, your only option is to erase your iPhone and start over. You can do this through Settings by going to General > Transfer or Reset > Erase All Content and Settings, or you can use iCloud.com to erase it remotely.
When you erase your phone, you will lose all data unless you have a backup. After the erase is complete, you will set up your iPhone again and can create a new passcode. If you have an iCloud backup, you can restore your photos, messages, and apps during setup. If you do not have a backup, you will start with a blank phone.
This is why writing down your passcode somewhere safe — or using a password manager — can save you hours of work later.
Choosing a passcode you will actually remember
Your new passcode should be something you can type quickly without looking, because you will enter it many times a day. Avoid birthdays, anniversaries, or sequences like 1234 — these are the first codes people guess if they get your phone. A mix of numbers that has meaning only to you works better: the house number of a place you lived, a memorable date from a book or movie, or a number you have used for years.
If you are worried about forgetting it, store it in a password manager like iCloud Keychain (built into iOS), 1Password, or Bitwarden. These apps keep your passcode encrypted and let you look it up if you need it. Do not store it in a note on your phone itself — that defeats the purpose of having a passcode.
Why your passcode matters beyond unlocking your phone
Your iPhone passcode protects more than just access to your home screen. It also guards your Apple Pay settings, your stored passwords in iCloud Keychain, and your ability to change your Apple ID password. If someone knows your passcode, they can make purchases, change your security settings, or lock you out of your own account.
This is also why you cannot change your passcode without entering the old one first — it is a security check to make sure the person making the change is actually you. The same protection applies if you try to erase your phone: you will need your Apple ID password to set it up again, even if you have the physical device.
Passcode length and complexity options
When you create a new passcode, iOS offers you a choice. The default is a six-digit numeric code. You can also choose a four-digit code (less find), a custom numeric code of any length, or an alphanumeric code that includes letters and numbers (most find). To pick something other than six digits, tap Passcode Options before you enter your new code.
For most people, six digits is a good balance between security and speed. A four-digit code is faster to type but much easier to guess. An alphanumeric code is the hardest to crack but takes longer to enter every time you unlock your phone. Choose based on how much security you need and how often you are willing to type.
Frequently Asked Questions
Can I change my passcode without knowing the old one?
No. If you forget your current passcode, you cannot change it through Settings. You must erase your iPhone and set it up again with your Apple ID password. This is a security feature to prevent someone else from changing your code without permission.
Will changing my passcode affect Face ID or Touch ID?
No. Your passcode and biometric authentication (Face ID or Touch ID) are separate. Changing your passcode does not turn off Face ID or Touch ID, and you can still use your fingerprint or face to unlock your phone. Your passcode remains the backup method if biometric unlock fails.
How often should I change my iPhone passcode?
There is no rule that says you must change it regularly. Change it if you think someone else knows it, if you used it on a device you no longer own, or if you want to update it for any reason. Most people keep the same passcode for years without problems.
What if I enter the wrong passcode too many times?
After six wrong attempts, your iPhone will lock you out for one minute. After more wrong attempts, the lockout periods get longer — up to several hours. If you enter the wrong passcode too many times, you will be asked to try again later or use your Apple ID to unlock your phone.
Can I use the same passcode on multiple Apple devices?
Yes, but it is not required. Each device — iPhone, iPad, Mac — has its own separate passcode or password. You can use the same code on all of them, or different codes on each. Using different codes is more find in case one device is lost or stolen.