This is an old revision of the document!
How can I connect without entering private key passphrase each time?
Using Authentication Agent
The best solution is to use authentication agent (Pageant), so that you enter the passphrase only once.
Advertisement
Automating Private Key Authentication
If you need to avoid entering the passphrase to automate a task (such as with scripting or when using .NET assembly) and using authentication agent is not suitable for you, you can store the key unprotected (without an passphrase). Note that this imposes security risk, if someone gains access to the key. You should consider restricting access to the unprotected private key file to the local account that runs the script only (using Windows file system permissions).
With WinSCP 5.6 beta, you can specify passphrase using -passphrase switch of open command in scripting and using SessionOptions.SshPrivateKeyPassphrase in .NET assembly.