File Transfer Protocol (FTP) is a protocol for uploading and downloading files from a remote server over a TCP port. The file transfer protocol is more than 40 years old and was developed before TCP / IP, and even more so HTTP, but it is still relevant and is used to connect to remote servers and exchange files.
This protocol uses different network connections to transfer commands and files between client and server. An FTP server is a computer with special software installed on it and waiting for external connection from other computers on 21 (standard) or another port.
Usually on hosting, file transfer takes place via FTP, because it supports multiple downloads, convenient access rights and good protection against unauthorized actions. The protocol itself implements two connections between the client and the FTP server.
The first control connection is used to authenticate the client on the FTP server, navigate the FTP server directory tree, etc. The second connection is used to transfer data (data connection) and is used to list data, transfer or receive server files.
In addition, there are also two modes of operation of the FTP protocol - active and passive. The control connection is the same for both active and passive modes. The main difference between the two is the side that opens the data connection. In active mode, the client accepts a connection from the FTP server, in passive mode, the client always initiates a connection.