Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top
C:\adc_ftp>ftp sysadmin:ftp@localhost <----Looking for a 1 line login like this
Unknown host sysadmin:ftp@localhost. <---doesn't work
ftp> bye

This works but not how I would like to log in:

C:\adc_ftp>ftp localhost 
Connected to
220-FTP server
    WarFTPd 1.82.00-RC11 (Sep 22 2006) Ready
    (C)opyright 1996 - 2006 by Jarle (jgaa) Aase - all rights reserved.
220 Please enter your user name.
User ( sysadmin
331 User name okay, need password.
230 User sysadmin logged in from host localhost (

I'm trying to make a batch file that logs into the ftp server. I tried examples like this one, but it doesn't take the login information and just sits at the "Please enter your user name".

share|improve this question
up vote 4 down vote accepted

From the example that you mentioned, be sure to use the -n flag to disable auto-login

C:\adc_ftp>ftp -n -s:ftp_script.txt localhost

Where ftp_script.txt contains something like:

Some ftp commands...
share|improve this answer
Thanks................... – Tommy Jan 20 '10 at 20:10

To do this, you need to make a text file.

For instance, to get a file that is located at this is my text file:

get /pub/README

I then call ftp using the -s parameter, like:

C:\Documents and Settings\eleven81\Desktop>ftp -s:ftp.txt

Which worked perfectly for me.

share|improve this answer
The separate txt file is what I was missing. I thought I could script opening ftp from the .bat. Thanks! (Now my bat file calls the .txt script.) – Tommy Jan 20 '10 at 20:23

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.