Windows – FTP/Windows/COmmand Line

command-line-interfaceftpwindows

How do I connect to my ftpserver from command line in just one command line.

For Example : ftp://hello.mydomain.com is my ftp server URL. I usually open a command prompt

Start -> Run -> cmd

and type ftp, which gives me the ftp prompt.

ftp> open hello.mydomain.com

It asks me the user id and password

username: me  
password: onlyme

And then I connect. However, I am trying to connect automatically without having the user id and password prompt?

something like

ftp>open hello.mydomain.com --username me --password onlyme

And it connects automatically without prompting the user ID and Password.

Best Answer

Anyway, this guy shows exactly how to do it:

ftp -s:script.txt ftp.server.com

and the contents of script.txt could be:

your_username
your_password
bin
cd /files
put file.zip
bye

where the first 2 lines of the file specify the username and password used for authentication.