Generating an SSH Key Pair for SFTP

Updated 4 days ago by James Dunn

SFTP requires that a SSH key be installed on the server to operate correctly. It is required to have an SSH key installed for the application to start up.

The steps to generate the key will differ based on your computer's Operating System:

Linux & macOS:

  1. Open a terminal window.
  2. Enter the following command:
    ssh-keygen -t rsa
    If you receive an error here, verify that you have OpenSSL installed. Then try again.
  3. Select the default values for all options.
    This command generates two SSH key files, id_dsa and, in the users home directory.
  4. Send the public key file to your partner representative.


  1. Download PuTTYgen.exe and run it. Putty gen is included with the windows MSI installer. 
  2. Launch Putty Key Generator and in the menu select key.Select the SSH-2 RSA radio button,  in the Parameters section near the bottom of the page select RSA. For number of bits in a generated key enter 2048.
  3. Click the Generate button.
  4. Move the mouse around in the blank area as instructed, until PuTTYgen generates the key pair.
    When PuTTYgen has generated the key, it replaces the blank area with a series of text boxes, including one that shows the public key.
  5. Click the Save public key button and save the public key with the name id-rsa in the folder C:\Documents and Settings\username\.ssh, where username is your Windows user name.
  6. Click the Save private key button and save the private key with the name id-rsa.ppk in the same folder.
  7. Copy to the clipboard the contents of the text box Public key for pasting into OpenSSH authorized_keys file.
    Make sure to copy the entire content, starting with ssh-rsa and ending with the email address you entered in Step 5.
  8. Close PuTTYgen.

How Did We Do?