How to FTP a file | How to download files from FTP

To FTP a file, connect to an FTP server using an FTP client, navigate to the desired directory, and then upload or download files by navigating to the respective local or remote directory and selecting the desired file action.
  1. Blog

For several decades, the file transfer protocol (FTP) served as the de facto method for transferring files across the internet. Organizations used FTP transfers to move multiple files or large files from one geographical location to another. Some businesses, for example, use FTP to upload files from their local PC to their web server.

In this blog post, you’ll learn how to FTP a file to an FTP server using a graphical FTP client. As a bonus, we’ll also briefly cover how you can upload and download files through the FTP command line.

Warning

FTP file transfers are no longer suitable for today’s business environments. The protocol was built at a time when network-based threats were not yet as prevalent as they are today. As such, FTP developers focused on ease of use and speed. The only security control included in standard FTP is basic password-based authentication.

If you wish to transfer sensitive files across the internet, or across any network for that matter, it’s better to use secure file transfer protocols. One option is FTPS, which stands for FTP-over-SSL. SSL refers to Secure Sockets Layer, the same cryptographic protocol used to secure web sites in the past. SSL has already been succeeded by Transport Layer Security (TLS), so most FTPS implementations actually use TLS instead of SSL.

Another option is SSH File Transfer Protocol (SFTP). SSH stands for Secure Shell, a cryptographic protocol primarily used to provide secure access to remote servers. Both FTPS and SFTP offer data-in-motion encryption and strong authentication.

Alright, let’s proceed with our main discussion. FTP file transfers are conducted under a client-server model. That means each FTP file transfer requires a pair of software applications: an FTP client and an FTP server. Let’s talk about those two types of applications first.

FTP file transfers

What is an FTP client?

An FTP client is the software application that your end users directly interface with. When an FTP user enters login credentials, selects a file or issues an FTP command, that user performs these actions against an FTP client. The client then works in tandem with an FTP server to respond to those actions or execute those commands.

FTP clients can have either a graphical user interface (GUI) or a character user interface (CUI). CUI-based clients are also known as command-line clients because you interface with them by entering commands manually on the command line. Of the two, GUI-based FTP clients are much easier to use. Users can interact with GUI-based clients through graphical menus, option buttons, buttons and other graphical elements.

GUI-based FTP clients usually come in the form of standalone software applications. Examples of this type of clients include FileZilla, AnyClient and CyberDuck. Some web browsers and even some operating system file management applications like Mac’s Finder and Windows’s Explorer come with FTP client capabilities as well.

connect to server

macOS Finder used as an FTP client

What is an FTP server?

As indicated earlier, an FTP client works in tandem with an FTP server to carry out an FTP file transfer. You would typically host your FTP server in your office, your data center or at a cloud service provider like Amazon Web Services (AWS), Microsoft Azure or Google Cloud Platform (GCP). A single FTP server can facilitate file transfers for multiple FTP clients.

FTP servers are great for file-sharing purposes. Once your users are connected to your FTP server, they can upload files to their personal folder or a shared folder. If files are uploaded to a shared folder, users who have access to that folder can download files uploaded by other users.

Some file transfer solutions like JSCAPE MFT by Redwood are equipped with both FTP client and FTP server functionality. That means these solutions can provide file transfer services to FTP clients. At the same time, they can also connect to other FTP servers and upload or download files from those other servers in what is known as a server-to-server file transfer.

server to server file transfer

In this blog post, we’ll just be focusing on basic user-initiated file transfers. However, if you wish to learn how to set up a server-to-server file transfer, click that link.

How to FTP a file using a graphical FTP client

Let’s now cover the basic steps for transferring a file using a graphical FTP client. The first thing you’ll need to do is establish an FTP connection.

How to establish an FTP connection

To establish a connection with an FTP server using an FTP client, you’ll typically need to enter the information listed below. You can obtain this information from the FTP server’s administrator.

  • IP address or hostname —This is the IP address (e.g. 10.0.0.161) or hostname (e.g. ftp.your company.com) of your FTP server.
  • Port number — This is the TCP port number your FTP server is listening on. Normally, this would be port number 21.
  • Login credentials — This consists of your user’s username and password. Your FTP server will use this information for authentication purposes. Some FTP servers support anonymous FTP. This is an FTP service that doesn’t require any type of authentication. Bear in mind that anonymous FTP is prohibited by most corporate security policies since it prevents you from enforcing accountability.

Some servers require additional information, such as:

  • Local directory — This is a directory in your client system. This is the default local directory from which files you wish to be uploaded will typically be retrieved. This is also where downloaded files will be stored by default.
  • Remote directory — This is a directory in your remote FTP server. This is the default remote directory where files that are uploaded to the server will be stored. This is also the default remote directory where files you wish to be downloaded will be stored.
  • Transfer mode — This can be either American Standard Code for Information Interchange (ASCII) or binary. The FTP data transfer mode is a property of your FTP data connection that indicates what type of file you’ll be transferring. For a more detailed discussion on transfer modes, read our article on FTP binary and ASCII transfer types.

Here’s an example of an FTP client graphical interface that accepts the information we detailed above. Once you’ve entered the required information, you can simply click the Connect button.

connect to server

Once you’ve established a connection with your FTP server, you can start uploading or downloading files. Let’s talk about those two operations next.

How to upload files

After you’ve successfully logged in, you should see two panels. One panel will show the file system on your local machine. Another panel will show you the file system on the remote server. In the sample screenshot below, the left panel represents the local file system, while the right panel represents the remote FTP server’s file system.

You can navigate into folders in the local file system and select files you want to upload. You can also navigate into the remote folder where you wish to store the uploaded files. Once you’ve selected the file(s) to upload, you may click the upload button. In the sample screenshot below, the upload button, which is only enabled once a local file is selected, is represented by a right arrow. Some FTP clients, like the one shown in the screenshot below, may display a graphical representation of the file transfer status.

ftp clients

Some FTP clients allow you to simply double-click the files you wish to upload, so you can try that action as well.

How to download files

In most cases, the download process is similar to the upload process. The main difference lies in the files you’re supposed to select. Instead of files in the local system, you’re supposed to select files in the remote system. Once you’ve selected the files you wish to download, you can try clicking the download button or double-clicking the files in question to initiate the download process.

How to copy files

When you upload files or download files, the original copies remain at the source. If you’re downloading files, the original copies remain in your server. And if you’re uploading files, the original copies remain in your local computer. That means you’re essentially copying files.

Using the FTP command line - A quick overview for beginners

While the process of uploading and downloading files via FTP is easier when carried out using a graphical FTP client, some people prefer to transfer files using the FTP command line. All major end-user device platforms, including Windows, Linux and Mac, come with built-in command-line FTP clients. That means you don’t have to download any additional software to carry out FTP file transfers.

If you’re comfortable with the terminal or command prompt, here are the basic commands for connecting to an FTP server, uploading files to that server, and downloading files from the server.

Command for connecting to an FTP server

ftp [hostname or ip address]

for example:

ftp ftp.example.com

or

ftp 10.0.0.161

You’ll then be asked to submit your username and then your password. If the authentication process succeeds, you can then start issuing commands for uploading or downloading files.

Command to upload files to an FTP server

mput [filename1] [filename2] ... [filenameN]

Note that each filename is separated by a space. So, for example,

mput file1.txt file2.txt file3.txt

Command to download files from an FTP server

mget [filename1] [filename2] ... [filenameN]

Again, each filename is separated by a space. So, for example,

mget file1.txt file2.txt file3.txt

For a more detailed discussion on the subject, read our step-by-step tutorial for working with the FTP command line.

Try a secure, automation-ready FTP server

Would you like to try an FTP server that also supports other files transfer protocols, including FTPS, SFTP and many others? We invite you to try JSCAPE MFT Server by Redwood, a multi-protocol managed file transfer server that can be installed on all major operating systems. JSCAPE MFT Server supports user-initiated file transfers and automated server-to-server file transfers. Get your 7-day trial of JSCAPE MFT Server now.

Downloads


The FTP client we used for this article is called AnyClient, a free, platform-independent client that supports a wide range of fast and secure file transfer protocols (e.g., FTPS, SFTP, WebDAV/S, AFTP) in addition to FTP. AnyClient runs on Windows, OS X, Linux, and Solaris.

Download the always-free AnyClient. Download Now