Using Your YubiKey with GitHub

Applicable Products


Requirements

  • Latest version of Google Chrome browser.
  • GitHub account.
  • U2F Security Key, YubiKey 4, YubiKey 4 Nano, YubiKey 4C, YubiKey NEO, or other Yubico U2F-certified YubiKey.
  • One finger (the YubiKey button is a capacitive sensor not a biometric).

How to Set Up Two-factor Authentication with GitHub

  1. Obtain a U2F YubiKey.
  2. In your GitHub account, set up two-factor authentication. If you already have 2FA set up, skip to the next step. To set up 2FA, do the following:
  3. Set up your YubiKey for GitHub. In your GitHub account, do the following:
    • Click your profile photo and click Settings.
    • On the left side of the screen, click Security.
    • Click Edit, and enter your password if prompted.
    • Scroll down to the section for Security Keys and click Register New Device. Follow the instructions as prompted.
  4. Configure a backup 2FA with one or both of the following  (and don't forget to keep your GitHub recovery codes in a safe place):
    • Fallback SMS number.
    • Recovery codes or Google Authenticator.

How to Use Two-factor Authentication with GitHub

  1. Log in with your user name and password.
  2. When prompted, insert your YubiKey and touch the blinking light. That's it!

Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.