Forgot Your Android PIN or Pattern? How to Get Back In

You changed your PIN last week, or you have been using your fingerprint for months, and now the phone wants the PIN and your mind is blank. It happens to a lot of people, especially after a restart.

Here is the honest situation first. Modern Android phones are built so that nobody can get past the screen lock without the PIN, pattern or password: not you, not a repair shop, and not Google. That is what keeps your data safe if the phone is stolen. There are a few genuine ways back in without losing anything, but they mostly depend on something you set up before you got locked out. If none of them apply, the way back in is a factory reset. This guide explains exactly what that costs you and how to keep the loss small.

Before Anything Else: Stop Guessing

Every wrong attempt adds a lockout timer, and the timers get longer each time. On some phones, too many wrong attempts can wipe the phone or lock it permanently. Samsung, for example, has cut the number of allowed attempts in One UI 9. After the 12th wrong try the phone is locked for 24 hours. On the 13th it is locked for good, and only a factory reset will recover it.

So before you keep trying combinations:

  • Write down the codes you have already tried, so you do not repeat them.
  • Try your most likely variations calmly: old PINs, your previous phone’s PIN, the same pattern drawn in a different direction, or a PIN with one digit changed.
  • Then move on to the options below rather than guessing until the phone locks for hours.

Option 1: Your Fingerprint or Face Still Works

If your phone still unlocks with your fingerprint or face, do not restart it. Android always asks for the PIN, pattern or password after a restart. On many phones it also asks for it every 72 hours when you use fingerprint unlock. If you lose that window, biometrics will not get you in again.

While you are in, back up everything right away (photos, WhatsApp chats, files), because you may still need a reset later. On most phones you cannot change the screen lock without entering the current PIN, but there are exceptions:

  • Samsung: if fingerprint or face unlock works but you cannot change the lock because you forgot the PIN, Samsung says you can reset the screen lock with Find My Mobile (now part of SmartThings Find). This only works if Remote unlock is turned on. More on this below.

Option 2: Samsung Phones: Use Your Previous PIN (If You Changed It in the Last 72 Hours)

Recent Samsung Galaxy phones with One UI 6.1 or later remember your previous screen lock for 72 hours after you change it. If you changed your PIN, pattern or password recently and forgot the new one:

  1. Enter a wrong PIN, pattern or password five times. A “Forgot PIN?” (or “Forgot pattern?” or “Forgot password?”) link appears.
  2. Tap it and enter your previous PIN, pattern or password.
  3. Choose a new screen lock and set it.

Be careful: you only get three tries at the previous lock, and the option can be used once per lock type. After 72 hours, the old lock is deleted and this option disappears.

Option 3: Samsung Phones: Remote Unlock With SmartThings Find

Samsung is the only big Android brand with a way to unlock a phone remotely without wiping it. It works only if all of these were true before you got locked out:

  • You were signed in to a Samsung account on the phone.
  • Remote unlock was turned on. The setting is in Settings > Security and privacy > Lost device protection > Find My Mobile, or Biometrics and security > Find My Mobile on older models.
  • The phone is switched on and connected to Wi-Fi or mobile data.

If those are in place:

  1. On a computer or another phone, go to smartthingsfind.samsung.com and sign in with your Samsung account.
  2. Select your locked phone.
  3. Choose Unlock and confirm with your Samsung account password.

The phone unlocks and your screen lock is removed, so set a new one immediately. If you have forgotten your Samsung account password too, reset it first from the Samsung account sign-in page, then try again.

If Remote unlock was never turned on, there is no way to switch it on now from outside the phone.

Option 4: Smart Lock or Extend Unlock

You may have set up Smart Lock to keep the phone unlocked in certain situations. It is called Extend Unlock on Samsung and newer Android versions, and it can keep the phone unlocked at home, while it is on your body, or near a trusted Bluetooth device such as your car or smartwatch. If so, it may still let you in. Go to the trusted place, or connect the trusted device, and try unlocking with a swipe.

This only works if the phone has not been restarted, because Android requires the PIN after every restart. On newer versions, trusted unlock also times out after a period of inactivity.

What About the “Forgot Pattern” Google Account Option?

You may read that you can tap “Forgot pattern” and sign in with your Google account. That option only existed on very old Android versions (Android 4.4 and earlier, from around 2013). It is not on any phone you are likely to own today. Guides that still recommend it are out of date.

When None of That Works: Factory Reset

If you cannot use any of the options above, the only legitimate way back into the phone is to erase it and set it up again. There are two ways to do it.

Erase It Remotely With Google Find Hub

This is the easiest method if the phone is switched on and online.

  1. On a computer or another phone, go to android.com/find (Google’s Find Hub, formerly Find My Device) and sign in with the Google account on the locked phone.
  2. Select the phone.
  3. Choose Factory reset device (or Erase device) and confirm.

Samsung owners can also choose Erase data in SmartThings Find.

Reset It With the Buttons (Recovery Mode)

If the phone is offline, you can reset it from recovery mode. The button combination varies by brand. It usually involves turning the phone off and then holding Power and Volume Up (or Power and Volume Down) until a menu appears. Use the volume buttons to select Wipe data/factory reset and the power button to confirm. If this does not work, search your exact model plus “recovery mode”.

After the Reset: You Will Need Your Google Account

Android phones have Factory Reset Protection. After a reset, when the phone starts up again, it asks for either the old screen lock or the Google account that was on the phone. This is what stops thieves from using a stolen phone.

So before you reset, make sure you know the email and password of the Google account on the phone, and that you can receive its verification codes. If you are not sure, sort that out first. If you have forgotten the password, our guide to Google account recovery when you are locked out covers what to do. On Samsung phones, you may also be asked for your Samsung account.

If you cannot provide either, the phone cannot be set up again, even by you.

What You Will Lose, and What You Can Get Back

A factory reset erases everything stored only on the phone. What comes back depends on what was backed up to the cloud before you got locked out.

Usually safe, if backup was on:

  • Photos and videos backed up to Google Photos (or Samsung Cloud or OneDrive on Samsung phones).
  • Contacts saved to your Google account.
  • Gmail, Google Drive files and Google Calendar.
  • The list of apps you had installed, plus some app data, if Google backup was turned on (Settings > Google > Backup). On many phones this also covers SMS messages and call history.
  • WhatsApp chats, but only up to your last chat backup to Google Drive. Sign in to the same Google account when you reinstall WhatsApp and choose Restore.

Usually lost:

  • Photos and videos that had not backed up yet.
  • Files in Downloads and other folders on the phone that were not synced anywhere.
  • WhatsApp messages since your last backup, and all of them if backup was off.
  • Codes in authenticator apps that do not back up to the cloud. If you used one for two-factor sign-in, you will need backup codes to get back into those accounts. Our guide on what to do if you lose the phone with your authenticator app explains how to recover.
  • Game progress and app data for apps that do not sync to an account.

A memory card (SD card), if your phone has one, is usually not erased by a reset, so anything stored there should survive.

Beware of “Unlock Without Losing Data” Tools and Shops

Search for this problem and you will find software, YouTube videos and repair shops promising to unlock any Android phone without losing data. Be very careful:

  • Many of these tools only work on old phones, simply factory reset the phone, or are scams that charge you and do nothing.
  • Some are malware.
  • Tools that bypass Factory Reset Protection are designed for stolen phones and may be illegal to use where you live.
  • A shop that “unlocks” your phone almost always does a factory reset, the same thing you can do for free.

If your phone is under warranty, the manufacturer’s official service centre can help with a reset, but they cannot recover data either. They will usually ask for proof that you own the phone, such as the purchase receipt.

Make Sure This Never Happens Again

Once you are back in, a few minutes now saves a lot of pain later:

  • Pick a PIN you will remember, and store it in a password manager. If you have never used one, our guide to how to start with a password manager explains the basics.
  • Use your PIN regularly. If you always use your fingerprint, unlock with the PIN once every few days so it stays in your memory.
  • Turn on backup: Google Photos backup, Google backup (Settings > Google > Backup) and WhatsApp chat backup. Our photo backup plan that works shows a simple setup.
  • On Samsung, turn on Remote unlock in Find My Mobile settings so you have a no-reset way back in next time.
  • Write your Google account email and password somewhere safe, so you can get through Factory Reset Protection if you ever need to.

Using an iPhone instead? The process is different. See our guide to iPhone Unavailable or Security Lockout.

Quick Answers

How can I unlock my Android phone if I forgot the PIN without losing data?

Only in a few cases:

  • On Samsung, you can use your previous PIN if you changed it in the last 72 hours.
  • Also on Samsung, you can use Remote unlock through SmartThings Find, if it was turned on beforehand.
  • Smart Lock or Extend Unlock may still work if you set it up and the phone has not restarted.

Otherwise, a factory reset is the only legitimate way back in.

Can I use my fingerprint if I forgot my PIN?

Yes, until the phone restarts or until it asks for the PIN as a security check, which on many phones happens every 72 hours. Do not restart the phone, and back up your data while fingerprint unlock still works.

Can Google unlock my phone?

No. Google cannot remove your screen lock. Find Hub can only locate, lock or erase the phone. After an erase, you sign in with your Google account to set it up again.

How do I factory reset a locked Android phone?

Use Google Find Hub at android.com/find to erase it remotely, or use recovery mode by turning the phone off and holding the power and volume buttons. After the reset, you will need the Google account and password that were on the phone.

Will a factory reset delete my photos?

It deletes photos stored only on the phone. Photos already backed up to Google Photos or another cloud service are safe and will reappear when you sign in again. Photos on a memory card are usually kept.

What happens if I enter the wrong PIN too many times?

The phone locks you out for longer and longer periods. On some phones, including Samsung phones with One UI 9, too many wrong attempts can lock the phone permanently, leaving a factory reset as the only option.

Will a repair shop be able to unlock my phone without a reset?

Almost never on a modern phone. Shops that “unlock” phones usually just factory reset them. Be wary of anyone promising to keep your data, and never use tools that bypass Google’s Factory Reset Protection.

Does a factory reset remove the Google account lock?

No. After a reset, Factory Reset Protection asks for the Google account that was on the phone. Make sure you know that account’s password before you reset.