5.9 KiB
title, intro, redirect_from, versions, topics, shortTitle
| title | intro | redirect_from | versions | topics | shortTitle | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Recovering your account if you lose your 2FA credentials | If you lose access to your two-factor authentication credentials, you can use your recovery codes, or another recovery option, to regain access to your account. |
|
|
|
Recover an account with 2FA |
{% ifversion fpt or ghec %}
{% warning %}
Warning: {% data reusables.two_fa.support-may-not-help %}
{% endwarning %}
{% endif %}
Using a two-factor authentication recovery code
Use one of your recovery codes to automatically regain entry into your account. You may have saved your recovery codes to a password manager or your computer's downloads folder. The default filename for recovery codes is github-recovery-codes.txt. For more information about recovery codes, see "Configuring two-factor authentication recovery methods."
{% data reusables.two_fa.username-password %}{% ifversion fpt or ghec %}
2. Under "Having Problems?", click Enter a two-factor recovery code.
{% else %}
2. On the 2FA page, under "Don't have your phone?", click Enter a two-factor recovery code.
{% endif %}
3. Type one of your recovery codes, then click Verify.

{% ifversion fpt or ghec %}
Authenticating with a fallback number
If you lose access to your primary TOTP app or phone number, you can provide a two-factor authentication code sent to your fallback number to automatically regain access to your account. {% endif %}
Authenticating with a security key
If you configured two-factor authentication using a security key, you can use your security key as a secondary authentication method to automatically regain access to your account. For more information, see "Configuring two-factor authentication."
{% ifversion fpt or ghec %}
Authenticating with a verified device, SSH token, or personal access token
If you know your {% data variables.product.product_name %} password but don't have the two-factor authentication credentials or your two-factor authentication recovery codes, you can have a one-time password sent to your verified email address to begin the verification process and regain access to your account.
{% note %}
Note: For security reasons, regaining access to your account by authenticating with a one-time password can take 3-5 business days. Additional requests submitted during this time will not be reviewed.
{% endnote %}
You can use your two-factor authentication credentials or two-factor authentication recovery codes to regain access to your account anytime during the 3-5 day waiting period.
- Type your username and password to prompt authentication. If you do not know your {% data variables.product.product_name %} password, you will not be able to generate a one-time password.
- Under "Having Problems?", click Can't access your two factor device or valid recovery codes?

- Click I understand, get started to request a reset of your authentication settings.

- Click Send one-time password to send a one-time password to all email addresses associated with your account.

- Under "One-time password", type the temporary password from the recovery email {% data variables.product.prodname_dotcom %} sent.

- Click Verify email address.
- Choose an alternative verification factor.
- If you've used your current device to log into this account before and would like to use the device for verification, click Verify with this device.
- If you've previously set up an SSH key on this account and would like to use the SSH key for verification, click SSH key.
- If you've previously set up a personal access token and would like to use the personal access token for verification, click Personal access token.

- A member of {% data variables.contact.github_support %} will review your request and email you within 3-5 business days. If your request is approved, you'll receive a link to complete your account recovery process. If your request is denied, the email will include a way to contact support with any additional questions.
{% endif %}