Github two factor authentication- How to Setup ?

This tutorial will explain , how to setup GitHub two factor authentication.


What is 2FA ?


Two-Factor Authentication(2FA) sometimes also called multi factor Authentication(MFA) ,is used to provide an extra layer of protection to secure online application such as GitHub , AWS account etc. 2FA allows an user to login into application using Authenticator App(Web or Moble) or using SMS etc after entering username and password.In Simple language , you need to login an online app using two authentication – First by entering username and password and then by putting code generated by Web/Mobile Authenticator App or SMS.


How to setup 2fa in GitHub ?


Here are step by step method that will show how to enable GitHub two factor authentication.


Step 1 –  Log in to your GitHub account and create repository.

If you do not have GitHub account yet, you can create it quickly by reading-

 How to create GitHub account quickly


Step 2 – After login, Click on Settings

Click on Avatar on the top right corner and navigate to Settings.


Step 3 – Navigate to User Security and  then Click on Enable two-factor Authentication



Step 4 –  Click on Set up using App



Step 5 – Download the recovery codes and click on Next

Download , Print , Copy or take screenshot of these recovery codes that will help you recover your account in case your Authenticator Stops working.


Step 6 – The following Screen will appear



Install Google Authenticator App


Step 7 – Install Google Authenticator app on your Mobile



Click on Get Started and then Click on scan a QR code



Scan the QR code from your app, on your Laptop/Computer as appeared in Step 6



As soon as you scan the QR code , GitHub account will be added on Google Authenticator.


Verify Github Two Factor Authentication

Verify if 2FA is working fine or not.


Step 8 – Sign out from GitHub account and Sign in again

Sign out from the account




Sign in again

It will ask for username and password as usual



It will ask for the 2FA . Enter the code from the Google Authenticator.

Click on Verify and you will be able to login your GitHub account




Thanks for reading this tutorial and hope you learned to Enable GitHub two factor authentication . If you think this article is really helpful, please do support us to share this article with others directly or via Social media.

Please also share your valuable feedback, comment, or any query in the comment box.I will really happy to resolve your queries.

Thank You

If you think we have helped you or just want to support us, please consider these:-

Connect to us: Facebook | Twitter

You may also like…

Leave a Reply

Your email address will not be published. Required fields are marked *