Custom Search

Ubuntu Linux ftp command line

This is a guide on how to connect to Ubuntu ftp using command line.

  1. Type ftp and enter to continue.

  2. Type open and enter to continue.

  3. Type ftp server ip address and enter to connect to ftp server.

  4. If connected, type login name and enter.

  5. Type user password and enter. If the username and password are valid, then you'll be in.

Here is the actual example from Ubuntu command line terminal:

luzar@ubuntu:~$ ftp
ftp> open
Connected to
---------- Welcome to Pure-FTPd [privsep] [TLS] ----------
220-You are user number 1 of 50 allowed.
220-Local time is now 10:42.
Server port: 21.
220-This is a private system - No anonymous login
220-IPv6 connections are also welcome on this server.
220 You will be disconnected after 15 minutes of inactivity.
Name (
331 User luzar OK.
Password required
230-User luzar has group access to:
luzar admin lpadmin fuse
230- plugdev video dip audio floppy cdrom dialout adm
230 OK. Current directory is /home/luzar
Remote system type is UNIX.Using binary mode to transfer files.

Now that you are already in the ftp server, let's check the Ubuntu ftp command that you can use. Type help:

ftp> help
Commands may be abbreviated. Commands are:
! debug mdir qc send$
dir mget sendport siteaccount disconnect
mkdir put sizeappend exit mls
pwd statusascii form mode quit
structbell get modtime quote systembinary
glob mput recv suniquebye hash
newer reget tenexcase help nmap
rstatus tickcd idle nlist rhelp
tracecdup image ntrans rename typechmod
lcd open reset userclose ls
prompt restart umaskcr macdef passive
rmdir verbosedelete mdelete proxy runique ?

That's all the ftp commands that you can use.The most important command in ftp is help. The ftp help command is similar to whatis command in Linux. The ftp help command syntax is . Here is an example of ftp help command:

ftp> help get
get receive file

You can also use ? to check ftp command meaning. It is the ftp help command short form. Here is an example of ftp ? command:

ftp> ? put
put send one file

You can use ls command to list a directory content in ftp server:

ftp> ls
200 PORT command successful
150 Connecting to port 39545
-rwxrwxrwx 1 luzar luzar 16 Nov 4 06:36 File.txt
drwx------ 3 luzar luzar 4096 Oct 21 11:14 folder
-rw-r--r-- 1 luzar luzar 89 Nov 4 09:48 mysql-init
-rw-r--r-- 1 luzar luzar 16 Nov 4 08:52 new-file.txt
226-Options: -l226 4 matches total

The ftp command used to download a single file from a server is get.

The ftp command used to download a multiple files from a server is mget.

The ftp command used to upload a single file to a server is put.

The ftp command used to upload a multiple files to a server is mput.

If you want to exit frm ftp, use ftp bye command.

That's the basic ftp commands you need to know to use ftp in the Ubuntu command line terminal. You can check the rest of ftp commands with help like the example above.

That's all.


  1. Hi, can you help me?
    1 - Is there a way to use this comand (ftp) to enter an ftp without the ip address?
    2 - Is there a way to sync 2 files (in the ftp server and in my computer) using this comand or other that you could know of from the comand line?

    What I want is a way to make an executable to sync files automatically when clicked...

  2. How to navigate to a location, which is given by link

  3. I am in Ubuntu rescue mode, and it seems ftp is not present on this distribution...

  4. how do I add the gui to my command line ftp installation, I have issues connection to my web admin console and would like to have local admin console access.

  5. We have an ftp server at work which is running in Ubuntu Command line mode. Our web admin console is not currently accessible, although we can log into our existing ftp accounts. What do I need to do to add an admin console to the existing ftp server so I can created/edit/delete accounts directly on the server rather than only being able to do that through the web browser remotely.


Please keep comment relevant and strictly no spam will be tolerated. Thank you.