sftp through a script

Guys

How can I use sftp through a shell script? OR is there is a more secure way to transfer files from one host to another (in a non-secure environment)?

Please help. I have tried various options. And I am currently doing the transfer of backups manually, I want to automate this.

Thanks all

KS

Try the info in this link from Snailbook.com