Connecting to SFTP using the Command Line

Modified on Fri, 28 Apr, 2023 at 12:35 PM

If your team is uploading files to the portal, it is best to automate the process. While there are many SFTP automation tools, most of them are command line diven. Please consult your SFTP software for full support. Below is an example of connecting using Windows SFTP that can be used for reference.


A successful connection will look like this:



Common Issue:

You get the error: WARNING: UNPROTECTED PRIVATE KEY FILE! or Permission Denied (publickey)



This error can be related to file permissions. SFTP can be very picky about the security of your key file. See directions of your SFTP client for more inforation about restriction access of this file if needed. Here is one thread that may be helpful for Windows users:


https://superuser.com/questions/1296024/windows-ssh-permissions-for-private-key-are-too-open/1296046#1296046


Summary For Windows Systems:

  1. Disabled all security inheritance on the key file.
  2. Give full permissions to the user who needs to access the file
  3. Remove permissions from everyone else.


Common Issue:

You get the error: Invalid Format


Your system may expect a differnt file format than the key provided. If this happens contact our support and we can assist you in coverting the key file to the necessary file format.


Permission Denied (publickey)



Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article