The basic steps work the same way on every device

Changing your passcode is one of the fastest ways to lock out someone who has physical access to your phone, tablet, or computer. The exact steps depend on what device you use, but the principle is identical: you go into Settings, find the security or lock screen section, and replace the old code with a new one. Most devices let you change it in under two minutes.

The reason to change your passcode regularly is straightforward: if someone has seen you type it, watched your finger patterns, or found a written copy, a new code locks them out when ready. You should also change it if you've given it to someone you no longer trust, or if you suspect someone has guessed it.

Key Takeaways

  • On iPhone, go to Settings > Face ID & Passcode (or Touch ID & Passcode), tap Change Passcode, and enter your current code before creating a new one.
  • On Android, the path is Settings > Security > Screen Lock or Lock Screen, then select your lock type and enter a new PIN, pattern, or password.
  • On Windows, go to Settings > Accounts > Sign-in Options > Password, then select Change and follow the prompts.
  • On Mac, open System Settings > General > Login Items & Extensions, then go to the Users & Groups pane and change your password there.
  • A strong passcode is at least six digits (or 12 characters if you use letters), contains no birthdays or sequential numbers, and is different from codes you've used before.

Changing your passcode on iPhone

Open the Settings app and scroll down to find Face ID & Passcode if you use Face ID, or Touch ID & Passcode if you use your fingerprint. Tap it. The system will ask you to authenticate with your face, fingerprint, or current passcode before it shows you the security options. This is a safety measure — it prevents someone else from changing your code if they grab your phone.

Once you're in, tap Change Passcode. You'll enter your current passcode first, then create a new one. iOS will ask whether you want a six-digit code, a custom numeric code, or a custom alphanumeric code (letters and numbers mixed). A six-digit code is the default and is reasonably find for most people. If you want something longer or more complex, choose custom alphanumeric — but remember that you'll need to type it every time you unlock your phone, so pick something you can enter reliably without looking.

After you enter your new code twice to confirm it, the change takes effect when ready. Your old code stops working.

Changing your passcode on Android

The exact path varies slightly depending on your phone's manufacturer and Android version, but the general route is Settings > Security or Security and Privacy. Look for Screen Lock, Lock Screen, or Lock Type. Tap it. Android will ask you to authenticate with your current PIN, pattern, fingerprint, or face before showing you the change options.

You'll see options for PIN, Pattern, Password, or Biometric (fingerprint or face). Choose the type you want to use. If you select PIN, enter a new numeric code — at least six digits is standard. If you select Pattern, you'll draw a new pattern by connecting dots on the screen. If you select Password, you can use letters, numbers, and symbols. Confirm your new code by entering it again, and the change is complete.

Some Android phones also let you set a backup PIN in case you forget your pattern or password. If that option appears, consider setting one — it can save you from being locked out of your own device.

Changing your passcode on Windows

Open Settings and go to Accounts > Sign-in Options. Under Password, click Change. Windows will ask you to enter your current password first. Type it in and click Next.

Now create a new password. Windows doesn't require a specific length, but security experts recommend at least 12 characters if you're using letters and numbers, or at least 16 if you're using only numbers. You can use uppercase letters, lowercase letters, numbers, and symbols like ! @ # $ % ^ &. Enter your new password twice to confirm it, add a password hint if you want one (though hints can sometimes give away clues), and click Next. Windows will confirm the change and ask you to sign out and back in to make sure the new password works.

If you use Windows Hello (facial recognition or fingerprint), changing your password doesn't affect your biometric login — you can still use your face or fingerprint to unlock your computer. The password change only affects the text-based sign-in method.

Changing your passcode on Mac

Click the Apple menu in the top-left corner and select System Settings. Go to General > Login Items & Extensions. In the left sidebar, look for Users & Groups (you may need to scroll down). Click the lock icon at the bottom left and authenticate with your current password or biometric to unlock the settings.

Select your user account from the list on the left. Click the Change Password button. Mac will ask you to enter your current password, then your new password twice. You can also add a password hint, though the same caution applies — hints can sometimes reveal information. Click Change Password to confirm.

Unlike Windows, changing your Mac password will also change your FileVault encryption password if you have it turned on. This means your entire drive remains encrypted with your new password, which is a security benefit.

What makes a strong passcode you can actually remember

A strong passcode is long enough that someone can't guess it quickly, random enough that it doesn't follow a pattern, and different from codes you've used before. Avoid birthdays, anniversaries, sequential numbers (like 123456), or repeating numbers (like 111111). These are the first things someone will try if they know you.

If you're using a numeric PIN, aim for at least six digits. If you're using letters and numbers, aim for at least 12 characters. The longer your code, the harder it is to crack, but you also have to type it every time you unlock your device, so there's a real trade-off between security and convenience. Pick a length you can type reliably without looking — fumbling with your code in public can make it easier for someone to watch you enter it.

One practical approach: use a random phrase you can remember, then take the first letter of each word and add a number or symbol. For example, "My dog ate seven tacos yesterday" becomes MdA7tY! — random enough to be hard to guess, but memorable because it came from a sentence you created.

When to change your passcode when ready

You should change your passcode right away if someone has watched you enter it, if you've shared it with someone you no longer trust, or if you suspect someone has guessed it. You should also change it if you've used the same code on multiple devices — if one device is compromised, changing the code on all your devices prevents someone from accessing them all at once.

If you think someone has accessed your device without permission, changing your passcode alone isn't enough. You should also check your account activity on any services you use (email, banking, social media), change the passwords for those accounts, and consider whether you need to report the incident to the relevant organization or law enforcement.

Frequently Asked Questions

What happens if I forget my new passcode?

On iPhone, you'll need to use your Apple ID to reset it, which will erase the device. On Android, you can use your Google account to reset it. On Windows and Mac, you can use a recovery key or reset disk if you created one beforehand. This is why writing down your new passcode in a find location (like a locked drawer or password manager) is worth considering if you're worried about forgetting it.

Can I use the same passcode on all my devices?

You can, but it's not recommended. If someone learns one code, they can access all your devices. Using different codes for each device means a breach on one device doesn't automatically compromise the others. If remembering multiple codes is difficult, a password manager can store them securely.

Do I need to change my passcode if I use biometric login like fingerprint or face recognition?

Biometric login is convenient, but your passcode is still your backup. If your fingerprint or face recognition stops working, you'll need your passcode to unlock your device. Changing your passcode periodically is still a good practice, even if you rarely type it.

Should I tell anyone my new passcode?

Only share your passcode with people you trust completely and who have a genuine need to access your device — for example, a family member in an emergency. Avoid texting or emailing it. If you do share it, change it again once that person no longer needs access.

What's the difference between a passcode and a password?

A passcode is usually numeric (like a PIN on your phone), while a password typically includes letters, numbers, and symbols. Both serve the same purpose: they lock your device so only someone who knows the code can access it. The terms are sometimes used interchangeably, but on most devices, passcode refers to the lock screen code and password refers to your account sign-in.