Skip to main content

How To Create SSH Keys on Mac

Instructions on how to create SSH keys on a Mac.

  1. Open the Terminal window
  2. Run the command
    ssh-keygen -b 4096 -t rsa 
    
  3. In the Enter file in which to save the key prompt enter the same text in the parenthesis but change id_rsa to your username_phs. That way it is identifiable
    Ex:
    Enter file in which to save the key (/home/youruser/.ssh/id_rsa): /home/youruser/.ssh/username_phs
    
  4. In the Enter passphrase prompt, give it a strong password. You will need this to log into the server
  5. Confirm your passphrase
  6. Type the following command and email me the text that it sends you:
    Remember to change youruser to your mac username.
    cat /home/youruser/.ssh/username_phs.pub