Flash Sale:75% Off Hosting + Free DomainEnds in13h47m14sView Plans
Hostvento logoHostvento

Set Up SSH Using cPanel

This guide shows how to make an SSH key in cPanel so you can log in to your hosting without typing a password.

WHM2 min read16 steps7 screenshots

What is SSH?

SSH (Secure Shell) is a safe way to type commands to your server from your own computer. An SSH key is a pair of files that act like a lock and a key. The server keeps the lock (the public key). You keep the key (the private key). When they match, you get in.

Keys are safer than passwords. Nobody can guess them. Whether SSH is on your plan depends on your setup. If you cannot see the menu below, ask Hostvento support.

Make a key pair in cPanel

  1. Log in to cPanel.
  2. In the Security section, click SSH Access.
    SSH Access tool
  3. Click Manage SSH Keys.
    Manage SSH Keys
  4. Click Generate a New Key.
    Generate New Key
  5. Leave the name as id_rsa, or type a name you like.
  6. Type a passphrase. A passphrase is a password that protects the key file. Pick a strong one.
    Generate Public Key
  7. Leave the key size at the default or choose a bigger size.
  8. Click Generate Key.
    Generate Key

Allow the key

  1. Go back to Manage SSH Keys.
  2. Find the public key in the list.
  3. Click Manage, then Authorize.

Now the server accepts that key.

Get the private key to your computer

  1. Next to the private key, click View/Download.
  2. Click Download Key and save the file in a safe place.

On Windows with PuTTY, you may need to convert the file. Use the button Convert to PPK if cPanel shows it.

Log in

  1. Open a terminal on your computer.
  2. Run this command. Use your own key path, username and server address:
ssh -i ~/.ssh/id_rsa username@your-server-address

This command logs you in using your key file. The server address and port are in your welcome email.

  1. Type the passphrase when asked.

Warning: Never share your private key. Anyone who gets it can enter your account. If you think it has leaked, go back to Manage SSH Keys and click Delete Key.

Tip: On Linux or Mac, set the key file so only you can read it with chmod 600 ~/.ssh/id_rsa. SSH refuses keys that are too open.

Open a support ticket if SSH Access is missing.

Quick recap

  • An SSH key is a safe replacement for a password.
  • Make it in SSH Access, then Manage SSH Keys.
    SSH Access Tool
    Import Key
  • Authorize the public key and download the private key.
  • Keep the private key secret.