Connect to github with ssh key

By | October 28, 2019

This is a straight forward list of steps to connect to github with a ssh key instead of user/password.

I am using Linux on my development machine so things are quite easy with ssh.

STEP 1: Create a ssh key

# ssh-keygen -t rsa -b 4096 -C “”

STEP2: Add the key to the authentication agent

# ssh-add ~/.ssh/id_rsa

STEP 3: Display the public key

# cat .ssh/

STEP 4: Copy the public key to the clipboard

STEP 5: Import the key to the account

Click on the profile icon -> Settings

Then under “SSH and GPG keys” in tge SSH Keys paste the New key from the clipboard

STEP 6: Clone a private repo using the new key

# git clone

All done , from now on any git operation using the private repo from github will no longer ask for user/pass but will use directly the secure connection using the ssh key.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.