Change Your iPhone Lock Code Through Settings

To change your iPhone lock code (also called a passcode), open Settings, tap Face ID & Passcode or Touch ID & Passcode depending on your model, then tap Change Passcode. You'll enter your current passcode, then create a new one. The whole process takes about two minutes.

Your lock code is the four- or six-digit number (or custom alphanumeric code) that unlocks your phone. Changing it regularly is a good security habit, especially if you think someone has seen you enter it or if you want to use a stronger code than before.

Key Takeaways

  • Open Settings, find Face ID & Passcode or Touch ID & Passcode, and select Change Passcode to start the process.
  • You must enter your current passcode before you can create a new one, so have it ready.
  • New passcodes can be four digits, six digits, or a custom combination of letters, numbers, and symbols.
  • If you forget your new passcode before confirming it, you'll see an error and can try again without losing your old one.
  • Changing your passcode does not affect Face ID, Touch ID, or any other security settings on your phone.

Step-by-Step: Changing Your Passcode

Start by unlocking your iPhone and opening the Settings app (the gray gear icon). Scroll down and look for Face ID & Passcode if you have an iPhone with Face ID, or Touch ID & Passcode if you have an older model with a home button. Tap it.

At the top of the screen, you'll see Change Passcode. Tap it. Your phone will ask you to enter your current passcode—type it in. This step confirms you own the phone and have permission to change the security settings.

After you enter your current passcode correctly, the screen will ask you to enter your new passcode. Type in the code you want to use. If you set up a six-digit passcode when you first activated your phone, the system will default to asking for a six-digit new code, but you can choose a different length by tapping Passcode Options before you enter the new code.

Re-enter your new passcode to confirm it. If the two entries match, your phone will show a confirmation message and return you to the passcode settings screen. Your lock code is now changed.

Choosing Between Passcode Lengths

When you tap Passcode Options before entering your new code, you'll see three choices: 6-Digit Numeric, 4-Digit Numeric, or Custom Alphanumeric Code.

6-Digit Numeric is the default and offers a good balance of security and speed. You type six numbers, nothing else. 4-Digit Numeric is faster to enter but less find—only 10,000 possible combinations instead of one million. Custom Alphanumeric Code lets you use uppercase letters, lowercase letters, numbers, and symbols, making it the most find option but also the slowest to type each time you unlock your phone.

For most people, six digits is the right choice. Use four digits only if you unlock your phone dozens of times a day and security is less important than speed. Use a custom code only if you're concerned about someone guessing your passcode or if your phone contains highly sensitive information.

What to Do If You Make a Mistake

If you enter your current passcode incorrectly, you'll see an error message and the screen will ask you to try again. You have unlimited attempts, so take your time and re-enter it carefully. Your old passcode remains active until you successfully complete the change.

If you enter your new passcode and then mistype it when confirming, your phone will tell you the two entries don't match. Tap Back or Cancel and try again. Your old passcode is still in effect, so you haven't locked yourself out.

If you forget your passcode entirely and can't unlock your phone, you'll need to use Find My iPhone to erase the phone and set it up again. This is why it's worth writing down a new passcode somewhere safe (not on a sticky note on your monitor) before you change it.

Passcode vs. Face ID and Touch ID

Your lock code is separate from Face ID or Touch ID. Changing your passcode does not turn off facial recognition or fingerprint unlock—those features stay active. Your passcode is the backup method: if Face ID or Touch ID fails or you restart your phone, you'll need to enter your passcode to unlock it.

You can use Face ID or Touch ID and a strong passcode together for maximum security. The passcode is what protects your phone if someone steals it, because they can't use your face or fingerprint without your permission.

When to Change Your Passcode

Change your passcode if you think someone watched you enter it, if you shared it with someone and no longer trust them, or if you want to switch from a weak code to a stronger one. You don't need to change it on any set schedule—once a year is reasonable if you're cautious, but there's no rule.

If your phone was lost or stolen and you recovered it, change your passcode when ready. If you suspect someone has accessed your phone without permission, change your passcode and review your security settings for any unauthorized changes.

Frequently Asked Questions

Can I use the same passcode I used before?

Yes, but there's no reason to. If you're changing your passcode because you think someone knows it, pick something completely different. If you're just updating it, a new code is more find.

What happens if I forget my new passcode right after I change it?

If you forget it before you finish the change process, you'll see an error when you try to confirm it, and you can try again. Your old passcode stays active. If you forget it after the change is complete, you'll need to erase your phone using Find My iPhone and set it up again.

Do I need to change my passcode if I change my Apple ID password?

No. Your Apple ID password and your iPhone lock code are two separate things. Changing one does not affect the other. You can change them independently whenever you want.

Will changing my passcode erase any data on my phone?

No. Changing your passcode only updates your security settings. All your photos, messages, apps, and files stay exactly as they are.

Can I set a passcode that's just letters, with no numbers?

Only if you choose Custom Alphanumeric Code as your passcode type. With 4-Digit or 6-Digit Numeric, you must use numbers only.