Transferring files to a server may be necessary when first publishing a website, replacing images, updating code, or moving a project to another platform. One way to do this is to connect to the server using an FTP client. However, FTP has an important limitation: a standard connection does not encrypt data. Before connecting, find out which protocol the server supports and use a secure option when available.
This article explains what FTP is, how it transfers files, how it differs from FTPS and SFTP, what connection details you need, and how to upload or update files and verify the result. If your website is hosted on a server or hosting service, use the access details provided for your specific environment: the server address, protocol, port, and permitted directory.
What Is FTP and How Does It Work?
FTP (File Transfer Protocol) is a network protocol for exchanging files between a client application and a server. The client may be a program on your computer, while the server is a remote system that stores website files. An FTP client lets users browse available directories, transfer files to the server, download them, rename them, or delete them, within the limits of their permissions.
FTP uses a client-server model. The user enters the host address, connection type, and login credentials. After authentication, the server grants access to the permitted part of its file system. This is not necessarily the entire server or the website’s root directory: access is often limited to the user’s home directory or a separate project directory.
FTP uses separate connections for control commands and data. The control connection is used to log in, navigate directories, and send commands; an additional data connection is established to transfer a file or directory listing. The standard control connection port for FTP is TCP 21, but encrypted modes, non-standard server configurations, and network rules may require different settings. The protocol specification is described in RFC 959.
FTP transfers data using a client-server model, but the details of the data connection depend on the mode. In active mode, the server establishes the data connection to the client. In passive mode, the client connects to a port specified by the server. Passive mode is often easier to configure when the client is behind NAT or a firewall, but connection availability depends on the configuration of both sides. If commands work but the file list does not open or a transfer stops, the cause may be the data channel or network rules.
What Can You Do with FTP?
The available operations depend on the account’s permissions and the server settings. Usually, a client lets you view files in accessible directories and perform operations on them. This can be useful for manually publishing individual files or small sets of changes, but connecting through FTP does not install a website or configure its software environment automatically.
After files are uploaded, a website will work only if the project structure, web root path, access permissions, web server configuration, database, and dependencies meet the application’s requirements. For a CMS-based website, for example, copying files may be only one step in the migration process; you may also need to export and import the database, update configuration settings, and check the domain.
- Upload new files or updated versions of existing files to the server.
- Download copies of existing files if the account has read permission.
- Create directories, rename items, or delete them if those operations are permitted.
- View the transfer queue and retry an operation if the client and server support resuming transfers.
Before replacing files in bulk, check whether the project contains hidden files, configuration files, or directories that must not be deleted or overwritten. FTP clients do not all display hidden items in the same way, and the file list may not include the database or other data stored outside the website directory.
When Should You Use an FTP Client?
An FTP client can be useful when you need to transfer files to a server manually, view the directory structure, or synchronize local and remote files. For example, you can use it to upload an image, an update package, or a configuration file. For moving a website to another hosting provider, FTP can be one of the tools involved, but it does not replace transferring the database, checking settings, or testing the website.
If you need to transfer many small files, upload time depends on their number, network latency, bandwidth, the number of parallel connections, and server limits. More parallel streams do not always mean faster transfers: the server may limit the number of simultaneous connections, and a large number of requests may create unnecessary load. When transferring a large project, use a method supported by the server and check whether you can upload an archive and extract it using the available server management tools.
For automated code deployment, version control and a configured publishing process may be more convenient. This approach is described in the article about using Git to deploy websites. The choice of method depends on the project structure, access permissions, and the tools supported by the server.
FTP, FTPS, and SFTP: What Is the Difference?
The names are similar, but these are not interchangeable versions of the same protocol. Standard FTP transfers login credentials and data without built-in encryption. FTPS adds TLS protection to FTP, while SFTP runs over SSH and is a separate file transfer protocol. When connecting, choose the exact connection type configured on the server.
| Protocol | How it works | What to consider |
| FTP | Transfers commands and files without built-in encryption. | Do not use it to transfer passwords or confidential data over untrusted networks. The standard control connection port is 21; the data channel is configured separately. |
| FTPS | Uses FTP with TLS protection. | The server may support explicit or implicit FTPS. Check the settings, certificate, and ports against the provider’s instructions. |
| SFTP | Transfers files over SSH; it is a separate protocol from FTP. | You need SSH/SFTP access to the server and the appropriate credentials. TCP 22 is the typical SSH port, but an administrator may configure a different one. |
| File manager | Lets you work with files through a browser-based control panel. | Availability depends on the control panel and account configuration. Convenience and limitations for large transfers may vary. |
SFTP and FTPS are different protocols. SFTP uses SSH, whereas FTPS is an FTP connection protected with TLS. The specification for securing FTP with TLS is described in RFC 4217, while SSH transport is described in RFC 4253. If the server supports several options, choose a protocol based on its documentation and your security requirements, not only on whether the client has a corresponding menu option.
SSH provides the secure transport for SFTP, while TLS is used to encrypt FTPS connections. In the program, select the correct protocol, security mode, and port. For example, entering port 22 does not turn FTP into SFTP: the selected protocol must match the service configured on the server.
A file manager in the control panel can be an alternative to an FTP client for small operations. These tools often let you upload, move, rename, or delete files without a separate program. Available features and operations depend on the control panel. Read more about the hosting control panel in a separate article.
What Do You Need to Connect?
Before launching an FTP client, prepare the details provided by the administrator or listed in the control panel. Do not guess the server address based on the website domain: the host used for file transfers may have a different name. Likewise, do not automatically use port 21 or 22 if a different port is specified for your environment.
- Server address. The hostname or IP address the client should connect to.
- Protocol. Check whether FTP, FTPS, or SFTP is available and which mode you need to select.
- Port. Enter the value specified in your connection details. The port number depends on the protocol and configuration.
- Username and authentication method. This may be a password or, for an SSH connection, a key if the server and client are configured to use key-based authentication.
- Starting directory. Find out where the account starts and which directory contains the website root.
- FTP connection mode. If the server uses standard FTP or FTPS, active or passive mode may be required; the selected mode affects the data channel.
Store passwords and private SSH keys as carefully as other credentials. Do not send them in public messages or leave saved sessions on a shared computer. If several people need access, it is safer to use separate accounts with the necessary permissions, if the server supports them.
Choosing an FTP Client
An FTP client is a program that connects to the server and displays local and remote files. Common clients include FileZilla, WinSCP, and Cyberduck. Protocol support and available features may vary by program version. Before connecting, check whether the client supports the mode you need – FTP, FTPS, or SFTP – and download it from the developer’s official source.
Many clients divide the interface into two panels: local files on your computer and remote files on the server. After connecting, you can select the required files and add them to the transfer queue. Before finishing, check for error messages and the status of each operation: a file still in the queue or transferred only partially should not be considered published.
Checking Access Permissions
Access permissions determine who can read, modify, or execute files. On Unix-like systems, some files and directories use permissions that graphical clients may display as CHMOD. Do not change them at random: permissions that are too broad can create a security risk, while overly restrictive permissions can prevent an application from working or new files from being uploaded. The correct values depend on the operating system, file owner, and the requirements of the specific website.
If the client reports an access error, first check whether the connected user has permission to perform the required action in that directory. Changing CHMOD does not always solve the problem: access may be restricted by account settings, file ownership, server policy, or the selected directory.
Setting Up an FTP Client
Menu names differ between programs, but the general process is similar. Create a new connection profile and enter the details provided by the administrator: the server address, protocol, port, username, and authentication method. For FTPS, also select the specified TLS mode; for SFTP, choose the corresponding protocol and enter a password or SSH key if key-based authentication is configured.
- Select a protocol the server actually supports.
- Enter the host address and port from your connection details.
- Enter the username and password, or configure another permitted sign-in method.
- For FTP or FTPS, check active or passive mode if you have problems with the data channel.
- Connect and make sure the expected directory opens and the website files are displayed.
- Before uploading, check the local folder and remote path so you do not overwrite another project.
If the client reports an unknown server SSH key or a TLS certificate error, do not ignore the warning automatically. Check the key fingerprint or certificate information against a trusted source, such as the administrator’s documentation. The warning may result from a configuration change, but its cause cannot be determined without verification.
How to Upload Website Files to a Server
Before uploading, find the directory from which the web server serves the website files. Names such as public_html, www, or htdocs are often used for the website root, but this is not universal. On a specific server, the directory may have another name or be set in the virtual host configuration. If you upload files to the wrong location, the connection may succeed, but the website will not change in the browser.
First, open the correct local directory and check that you are uploading the project files themselves, not a parent folder with extra levels of nesting. For example, after an archive is transferred, the website may end up in a subdirectory even though the contents of that directory were expected at the root. For an existing website, compare the directory structure and do not delete files if you do not know what they are for.
- Check the project files locally. Make sure all required files, configuration files, and directories are present. Do not include test data, backups, or secrets that should not be accessible on the web.
- Open the correct website root. Check the path in the control panel or in the details provided by the administrator.
- Transfer the files. Add the required items to the client queue and wait for the transfer to finish. If the client reports errors, check the affected files rather than assuming the whole operation succeeded.
- Check the structure and permissions. Make sure the files are in the correct directories and that the web server can access them.
- Check the website in a browser. Open the main pages, images, and features that depend on the uploaded files. Check the application or web server logs if needed.
Optimizing images and removing unnecessary files before uploading can reduce the amount of data transferred, but do not change the project structure just to improve speed without checking the CMS or application requirements. Archiving a large number of files may be more convenient, but the way to extract an archive depends on the tools available on the server. Do not assume that the FTP client or control panel will extract it automatically.
How to Update a Website via FTP and Reduce the Risk of Errors
Transferring files does not guarantee an update without downtime. If you replace files on a live website one by one, visitors may temporarily receive an incompatible mix of old and new versions. A network failure, incorrect path, incomplete upload, or configuration differences can also cause errors. The following steps outline a cautious process for manual updates.
- Create a backup. Save copies of the files and database separately from the working directory. Copying files through FTP does not, by itself, create a complete website backup, especially if the database is stored separately. Make sure the backup can be read or restored; see the separate article on backups for more information.
- Prepare a list of changes. Identify which files need to be added, replaced, or deleted. Do not delete the entire website directory before uploading a new version unless you have a verified recovery procedure.
- Test the update before publishing. If a test environment is available, deploy the changes there and check pages, forms, scripts, images, and integrations. Creating a directory named staging does not, by itself, make it a complete test environment.
- Upload the required files. Use the protocol and directory specified for this server. Do not change the configuration or access permissions at the same time unless necessary.
- Check the transfer result. Make sure the queue has finished without errors and that the files have the expected size and location.
- Check the website. Open key pages and features, and check error messages and logs if available. If problems arise after the update, use the recovery procedure prepared in advance to restore the previous copy.
If a project requires continuous availability during updates, an FTP client alone cannot guarantee that there will be no interruption. You need a separate deployment procedure that takes the application’s behavior, file structure, and database into account. Test it in advance and apply it to the specific infrastructure.
Security When Using FTP
The main limitation of standard FTP is that the protocol does not encrypt credentials or transferred files. This means that, under certain conditions, a network observer may be able to read commands, passwords, or the contents of a transfer. The risks of standard FTP are described in RFC 2577. For file transfers over untrusted networks, use FTPS or SFTP configured on the server.
Encrypting the connection does not eliminate every risk. It does not fix a weak password, excessive access permissions, or a mistake in the selected directory. Follow these rules:
- Use separate credentials for file transfers and a strong, unique password; use the password generator if needed.
- Use FTPS or SFTP if the server supports them, and verify the TLS certificate or SSH key.
- Give users only the permissions and directory access they need to do their work.
- Do not store passwords or private keys in a shared user profile or unprotected text files.
- Do not leave an open session on someone else’s device; disconnect when you finish.
- Before deleting or replacing files in bulk, check the remote directory and website name.
Change access permissions only when you understand the cause of the error and know the values required by the application. Do not set the most open permissions “just to test”: this could make files vulnerable to unwanted changes. If file permissions or ownership do not match the server settings, contact the environment administrator.
Common Errors and How to Troubleshoot Them
An FTP client message may point to different causes: incorrect login details, denied permissions, a network restriction, or a problem with the data channel. Start troubleshooting by checking the specific message and connection log rather than changing all the settings at random.
| Message or situation | Possible explanation | What to check |
| 530 Login incorrect / Not logged in | The server did not accept the credentials, or the wrong protocol was selected. | Check the address, protocol, username, and sign-in method. Make sure the account is active. |
| Permission denied / Access denied | The user does not have permission to perform the required operation or access the directory. | Check the path, account permissions, and file system permissions. Do not change CHMOD values unless you understand the required settings. |
| Connection timed out | The host is not responding, the connection is blocked by the network, or the settings are incorrect. | Check the address and port against your connection details; check the VPN, firewall, and server availability. |
| Connected, but the file list will not open | The data channel may be blocked, or the FTP mode may be configured incorrectly. | Check active or passive mode, network rules, and the administrator’s instructions about data ports. |
| Transfer interrupted / Failed transfer | The connection was interrupted, the server rejected the operation, or the transfer did not finish. | Check the log, available disk space, and server limits; retry after identifying the cause. If supported, check whether the transfer can resume from the point where it stopped. |
| The file uploaded, but the website did not change | The file may have been uploaded to the wrong directory, may not have replaced the intended version, or the result may be cached. | Check the remote path, file name, website root, and browser or application cache. |
If the error persists, save the client log with the server’s response and check the connection settings with the administrator. Do not send a password or private key with the log: remove confidential information before sharing it. If the server supports FTPS or SFTP, make sure the client is using that protocol rather than standard FTP.
Conclusion
FTP is a way to manage files on a server and can be useful for manually uploading and updating a website. However, standard FTP does not encrypt transfers, so a successful connection does not make it secure. FTPS protects FTP with TLS, while SFTP transfers files over SSH; check the protocol, port, and permissions against the configuration of the specific server.
Before transferring files, identify the correct website directory, prepare a backup, and check that all files uploaded successfully. After the update, review the website and test its important features. This process helps you find errors sooner and restore the project, but it does not replace a test environment or a specifically configured deployment process when one is needed.


