How to log into Facebook if you have lost access to the code generator

How to log into Facebook if you have lost access to the code generator

Find out how to set up 2FA on Facebook and what to do if you lose access to Code Generator when you try to log in.

Yes, you can log into Facebook without a confirmation or recovery code. Facebook's code generator is just one of Facebook's many levels of security.

We'll show you how to log into your account using alternatives to receiving a Facebook confirmation code.


Why do you need a Facebook confirmation code?

After enabling Facebook's two-factor authentication, which we highly recommend, Facebook will ask you for a security or confirmation code to log in from a new location or device. Read our guide on two-factor authentication and why you should use it to learn more about this security method. Without two-factor authentication, you only need your username or email address and password to log into your Facebook account.


By enabling Facebook two-factor authentication, you have added an extra layer of security, which can protect your Facebook account from being hacked.

Where can you find a Facebook confirmation code?

You can get a Facebook login code in three different ways:

  • Facebook can send an SMS confirmation code to a mobile number associated with your account.
  • From an authentication app, such as Duo or Google Authenticator. Additionally, the Facebook mobile app includes a code generator that automatically generates a new security code every 30 or 60 seconds.
  • From a list of Facebook recovery codes that you have saved as a backup.

In addition to the codes, you can also create a second factor physical security key to log into Facebook via USB or NFC.



Since two of the above methods depend on a mobile device, make sure you have at least one other method to log back into Facebook if your device is lost.

How to set up Facebook two-factor authentication

To enable two-factor authentication, open Facebook in your browser, click the arrow in the top right to expand the navigation menu and go to Settings and privacy> Settings> Security and login . In Two-factor authentication , click your Modification next to Use two-factor authentication . You may need to enter your password at this point.

To enable two-factor authentication, select the method you want to use for Facebook verification. You can proceed with an app of authentication (recommended), a text message (SMS) or a security token. Make your selection and click NEXT .

We went with the SMS option and entered the six-digit code that Facebook sent to our mobile number. You can use a phone number that is already associated with your account or add a new one. After entering the Facebook confirmation code, click end to complete the initial setup.

Now you can add an authentication app, save recovery codes and create a security key - click Setup next to the respective method. You can also change the phone number that Facebook uses to send you a text message with an access code; just click Manage next to the Text Message (SMS) option.

If the Google Authenticator app code doesn't work while you are setting it up as a 2FA method, open the Authenticator app, tap the three dots icon at the top right and select Settings> Time Correction for Codes . It should now work.


If you need to temporarily disable two-factor authentication, just click disable on Facebook's 2FA settings page and you will be able to log in using your basic login credentials.


How to access the Facebook code generator

Code Generator is a convenient way to access two-factor authentication codes without a mobile number. The tool will come in handy when you're on the go or don't have mobile reception. Code Generator is available within the Facebook app for iOS and Android.

To access Facebook Code Generator from Android or iOS, open the Facebook app , click hamburger icon top right, scroll down, expand the menu Settings and privacy and select Code generator . Here you will see the tool run new security codes every 30 or 60 seconds.

Lost your phone and can't use the code generator?

When you've set up your phone as a key for your Facebook account, losing or breaking it could be a problem. Here's what you can do if you lose access to Code Generator.

Let Facebook send you a confirmation code

Do you still have access to the mobile number you included in two-factor authentication? Perhaps your provider could send you a new SIM with the same number. If so, let Facebook send you a confirmation code. Unfortunately, Facebook can only use that number for two-factor authentication, even if you've set up other phone numbers in your profile.

From the screen asking for your passcode, select Do you need another way to authenticate yourself? (bottom left), then click Send me an access code and wait for the text to arrive. You can also get Facebook to call you.


Use a saved recovery code

After setting up two-factor authentication, you had the option to save a set of recovery codes as a backup. Maybe you printed the code, took a screenshot, or wrote it down and stored it in a safe place.


If you haven't saved your recovery codes, be sure to do so as soon as you've regained access to your account. If you ever lose access to Code Generator again, you can use one of these codes to log into Facebook from a new device or location.

Approve access from an authorized device

Whenever you successfully log into Facebook from a new device, application or browser, Facebook asks you if you want to remember it. You won't need a passcode the next time you want to log into Facebook from that authorized device and location. Now that you can't access Code Generator, this could be your private backdoor in your Facebook account.

Try logging into Facebook from a browser or app you've used before. Maybe you're still signed in on an old laptop, work computer, or tablet. When you find a device on which you can still log into Facebook, you should see a notification asking you to approve the new login.

Confirm your identity

None of this works? Send a request to Facebook. In the menu that opens after selecting You need another way to authenticate (see option 1), select Get more help and let Facebook walk you through the steps to recover your account.

You will need to enter an email address and upload a copy of your ID, which can be a passport, driver's license, national ID card or other official documents.

After providing the requested information, Facebook will send you an email with further account recovery steps.

You can also access the recovery path above via any browser, desktop or mobile. Go to and log into your account using your mobile number, email or username and password. When prompted for the passcode, click Problems? > I don't have my phone> Continue .

On the next screen, Facebook will tell you to log in from a known browser. If this isn't an option, click Contact us . As above, you will need to provide an email address, ideally linked to your account, and upload your ID and a message to Facebook.

Were you able to log into Facebook again? Remember to save your recovery codes, set up a new authentication app, and update your other recovery options.

Are you back on Facebook but lost your mobile device?

To prevent access to your Facebook account from a lost phone or laptop, log out of the app's Facebook session. If you have registered your phone number, go to Facebook> Settings and Privacy> Settings>> Lost your phone? and click on the button Disconnect on the phone .

At this point, you should To remove the lost phone number.

If you have lost a device other than your phone or if you have not set up your mobile number, there are several ways to log out of Facebook from other devices.

Go up Facebook (on a recognized device) > Settings and security> Settings> Security and login> Where did you start from access, find the respective session e Logout . If in doubt, terminate multiple sessions. This will log you out of the app.

Until you restart your phone or set up Code Generator on a new phone, you can save a batch of backup codes as described above. You can also set up another third party app to generate codes.

And in the future, always make sure that at least one device, other than your laptop or phone, has authorized access. It could be a home computer that you will always have access to. Only allow Facebook to remember devices and locations that are private and safe. And frequently review your list of e Remove obsolete items.

For security, also update your Facebook password.

add a comment of How to log into Facebook if you have lost access to the code generator
Comment sent successfully! We will review it in the next few hours.

End of content

No more pages to load