I created a pair or RSA keys using Putty key generator, The Public key is attached set on the server side. The private key at windows client machine and being used with pageant and FileZila and working fine. Now Problem is that when I want to connect same sftp through PSFTP commandline tool, it failes. if possible please provide steps to setup ssh key on windows client to access sftp using psftp or direct through batch file.

2 Answers 2


If pageant is running and has the key loaded psftp should use it. It does on my system. Exactly how does it fail for you? plink should use pageant the same way; does it work? How about putty user@host (not using a saved session)?

According to the manual http://the.earth.li/~sgtatham/putty/0.63/htmldoc/Chapter6.html#psftp-pubkey option -i or a saved session containing Auth should also work, but I haven't tried them.


Make sure you are using the same version of Pageant and psftp. Some versions are not compatible.

If this does not help, run psftp -v and try again and include console output to your question.

Ideally you should see something like:

Pageant is running. Requesting keys.
Pageant has 2 SSH-2 keys

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .