How to easily connect FTP server from Linux Terminal

FTP server is widely used in setup which involves frequent transfer of files. Although multiple GUI based FTP clients are available but still you may need connect FTP server from Linux terminal on Server environment without GUI.

FTP commands to perform connection to server, Listing files Download and Upload files in FTP server

Before starting you need a configured working FTP server.

To connect to remote FTP server you will need

  1. IP address of FTP server and port for Server default is 21
  2. User name for FTP account
  3. Password for FTP user

Connect FTP Server from Linux terminal

In terminal type


ftp server name or IP address

If domain name is different than default type server name / ip address followed by :portnumber (


ftp infojinx

Once you are connected to ftp server, it will ask for username and password, enter them as asked.

Transfer files from / to FTP server

Listing files on FTP Server from Linux terminal

Once connected check files available. To check you need to use list (ls) command.



Changing Directories on FTP Server from Linux terminal

Changing directories on server is simple just use cd command


cd <directory name>

cd test

Downloading files from FTP Server using Linux terminal

Downloading files from remote ftp server requires to things – first you need to set up local download path and downloading files

to set local path use command lcd

lcd /home/user/local_directory_name

If you have started ftp session from local directory into which you want to copy file, you can skip this step.

Finally to download file type

get file_name

Uploading files to FTP Server from Linux terminal

To upload files to remote ftp server you need to use command

put file_name

similiar to downloading files you can change local directroy by using lcd command.

Disconnecting FTP connection made from Linux terminal

To disconnect working FTP session you can use bye/exit/quit command.


Other articles which will interest you

How to configure FTP Server in Linux