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. After you do, tap Change Passcode at the top of the screen. Enter your current passcode one more time, then enter your new passcode twice — the second time to confirm it matches what you typed the first time. Tap Done when finished.

The entire process takes less than a minute. Your new passcode takes effect when ready. If you forget it before you leave the Settings screen, you can tap Change Passcode again and start over.

Key Takeaways

  • You need your current passcode to change it — if you have forgotten it, you will need to erase your iPhone and set it up again.
  • Your new passcode can be four digits, six digits, or a mix of numbers and letters, depending on what you choose during setup.
  • The change happens when ready and applies to all features that use your passcode, including Face ID unlock and App Store purchases.
  • If you change your passcode, any saved backups encrypted with your old passcode will not restore without the old code.

Choosing between four digits, six digits, or a custom code

When you tap Change Passcode, iOS asks what type of passcode you want. The default is six digits. If you select Passcode Options, you can choose four digits (faster to type but easier to guess), six digits (the middle ground), or Custom Alphanumeric Code (letters and numbers, hardest to guess but slowest to enter).

Most people stick with six digits because it balances speed and security. A four-digit code is convenient if you unlock your phone dozens of times a day, but it offers less protection. A custom code is strongest but requires you to type it out letter by letter, which gets tedious.

What happens if you forget your current passcode

If you cannot remember your current passcode, you cannot change it through Settings — iOS will not let you proceed without entering the old one first. Your only option is to erase your iPhone and set it up again from scratch or from a backup.

To erase your iPhone, go to Settings > General > Transfer or Reset > Erase All Content and Settings. You will be asked to enter your passcode, your Apple ID password, or both, depending on your setup. After the erase completes, you can set up your iPhone as new or restore from a backup. If you restore from a backup that was encrypted with your old passcode, you will need that old passcode to complete the restore.

Passcode versus Face ID and Touch ID

Your passcode is separate from Face ID or Touch ID, but they work together. Face ID or Touch ID lets you unlock your phone without typing anything. Your passcode is the backup — if your face or fingerprint does not work, or if you have not unlocked your phone in several days, iOS asks for your passcode instead.

Changing your passcode does not affect Face ID or Touch ID. Both will continue to work as they did before. If you want to turn off Face ID or Touch ID entirely, you can do that in the same Face ID & Passcode settings screen, but you will still need your passcode to unlock your phone.

How your new passcode affects backups and Apple ID

If you have turned on encrypted backups in iCloud or on a computer, your old passcode was used to encrypt those backups. After you change your passcode, new backups will use the new one. Old backups encrypted with your previous passcode will still require that old passcode if you ever need to restore from them.

Your Apple ID password is separate from your iPhone passcode. Changing your iPhone passcode does not change your Apple ID password, and you do not need your iPhone passcode to sign into your Apple ID on a different device. If you want to change your Apple ID password, you do that through Settings > [Your Name] > Password & Security > Change Password.

Troubleshooting if the change does not go through

If you tap Done but the passcode does not seem to change, the most common cause is that you typed your new passcode differently the second time. Go back to Face ID & Passcode, enter your current passcode, and try again — make sure both entries of your new code match exactly.

If you see an error message saying your new passcode is too similar to a recent one, iOS is preventing you from reusing a code you have used before. Choose something different. If your iPhone is frozen or unresponsive, restart it by holding down the power button and volume button together until the power-off slider appears, then slide to power off. Wait a few seconds, then hold the power button again until the Apple logo appears.

Frequently Asked Questions

Can I use the same passcode I used before?

No. iOS prevents you from reusing a passcode you have used recently. If you try, you will see a message saying your new passcode is too similar to a recent one. You must choose a different code.

Do I need to change my passcode regularly?

There is no requirement to change your passcode on a schedule. Change it if you think someone else knows it, if you have shared it with someone you no longer trust, or if you straightforward want a fresh one. Otherwise, a strong passcode that only you know is sufficient.

What if I change my passcode and then forget the new one?

You will need to erase your iPhone and set it up again. There is no way to recover a forgotten passcode. Write down your new passcode in a safe place, or use a password manager to store it.

Does changing my passcode log me out of apps?

No. Apps remain signed in and do not require you to re-enter passwords. Your passcode is only used to unlock your phone and to authorize certain actions like App Store purchases or changing settings.