How to authorize your public key in cPanel and DirectAdmin?

cPanel and DirectAdmin provide a seamless interface to authorize your public key. Authorizing the public key is required to connect to your hosting account or server via SSH or SFTP.

 

Authorize the Public Key in cPanel


To connect to a cPanel-based hosting account:

  • Go to cPanel > SSH Access > Manage SSH Keys > Import Key.

    Paste your public key in the box labeled "Paste the public key into the following text box".

    Click "Import".

    Click "Back to Manage Keys" after the "The key named '' was imported." message appears.


  • Click "Manage" next to the key you imported (in the "Public Keys" section, under the "Actions" column).

    Click "Authorize".

    Click "Go Back" after the "The key id_rsa.pub has been authorized." message appears.

  • Done!

 

Authorize the Public Key in WHM


To connect to a cPanel-based VPS or Dedicated Server as the root user:

  • Go to WHM > Security Center > Manage root's SSH Keys > Import Key.

    Paste your public key in the box labeled "Paste the Public Key in this box".

    Click "Import".

    Click "Return to SSH Manager" after the "The public key... was imported." message appears.


  • Click "Manage Authorization" next to the key you imported (in the "Public Keys" section, under the "Actions" column).

    Click "Authorize".

    Click "Return to SSH Manager" after the "...pub has been authorized" message appears.

  • Done!

 

Authorize the Public Key in DirectAdmin


To connect to a DirectAdmin-based hosting account:

  • Add your public key in DirectAdmin > Users > Advanced Features > SSH Keys > Paste Key.

  • Select the key and click Authorize to enable it.

  • Done!

 

You should now be able to use the private key in your SSH/SFTP client to connect.

 

  • 327 Users Found This Useful
Was this answer helpful?

Related Articles

How to limit the number of FTP connections?

When uploading a large number of files, we recommend you limit the number of FTP connections....

How to upload a large number of files quickly via FTP or File Manager?

Uploading a large number of times usually takes a lot of time. Your computer and server traverse...

How to enable and access SSH?

SSH remains disabled by default on all hosting accounts (excluding VPS and Dedicated Server). If...

How to connect to SSH from Mac?

SSH access must be enabled for your hosting account (excluding VPS and Dedicated Server) to...

How to connect to SSH using Command Prompt in Windows?

You need to use key-based authentication in your SSH/SFTP client (the software you are using to...