SSH key for GitHub (2023)
Apr 13, 2023
How to setup ssh keys for GitHub macOS 2023
Generate SSH keys
- Run ssh keygen command
ssh-keygen -t ed25519 -C "<Your_Github_Email>"- When asks for file just press enter
Enter file in which to save the key (/Users/eduardjacobs/.ssh/id_ed25519):- Enter your Passphrase
Enter passphrase (empty for no passphrase):
Enter same passphrase again: - Start ssh agent in the background
eval "$(ssh-agent -s)"- Modify ssh config
Get Eduard Jacobs’s stories in your inbox
Join Medium for free to get updates from this writer.
nano ~/.ssh/config- paste setup command than press
control + Xthany + Enter
Press enter or click to view image in full size![]()
Host github.com
AddKeysToAgent yes
UseKeychain yes
IdentityFile ~/.ssh/id_ed25519- Add ssh key to ssh-agent
ssh-add --apple-use-keychain ~/.ssh/id_ed25519- Copy public key
pbcopy < ~/.ssh/id_ed25519.pub- Go to you Github Settings -> SSH and GPG keys -> Add ssh key
- Copy and Paste key.pub







