WIN FIFA World Cup™ tickets! Raffle closes in:

WIN FIFA World Cup 2026™ tickets! Enter now

Sign up now
Wc2026 Mobile

Expressvpn Glossary

Secure File Transfer Protocol (SFTP)

Secure File Transfer Protocol (SFTP)

What is Secure File Transfer Protocol?

Secure File Transfer Protocol (SFTP) is a network protocol used to securely transfer, access, and manage files on a remote system. It runs over Secure Shell (SSH), which encrypts the connection to protect both data and commands during transfer.

SFTP was developed as a safer replacement for File Transfer Protocol (FTP), which can send login credentials and file data in plaintext. As a result, FTP is far more vulnerable to interception.

Despite the similar name, SFTP isn’t just FTP with added encryption. It’s a separate SSH-based file transfer protocol, commonly implemented with SSH-2, which is the standard most modern SSH implementations follow. That makes it suitable for secure file exchanges in business, IT, and other environments where sensitive data needs protection.

How does Secure File Transfer Protocol work?

SFTP begins with an SSH connection between a client and a server, typically over Transmission Control Protocol (TCP) port 22, the same port SSH uses by default. The client then authenticates the user with a password or an SSH key. Once authentication succeeds, SFTP runs as an SSH subsystem and uses the encrypted connection to handle file operations.

SFTP typically uses one SSH connection to carry both commands and file data. The client sends requests such as open, read, write, or close, and the server returns matching responses. This request-response structure lets users upload, download, and manage files remotely without exposing anything in plaintext.

SSH encrypts all data in transit and uses integrity protection to help detect tampering during the session. Using a single connection rather than separate control and data connections also simplifies firewall and Network Address Translation (NAT) configuration. By contrast, FTP and File Transfer Protocol Secure (FTPS) rely on separate control and data connections, with data ports that may be negotiated dynamically, which can make them harder to secure at the network level.The Secure File Transfer Protocol workflow.

Why is Secure File Transfer Protocol important?

Here's how SFTP helps keep file transfers safe:

  • Protects file contents in transit: SFTP encrypts both file data and transfer commands, helping protect information from exposure during transmission.
  • Secures authentication: Unlike FTP, which sends login credentials in plaintext, SFTP uses SSH to protect authentication and verify the server connection.
  • Protects data integrity: SSH integrity checks help detect tampering during the transfer.
  • Supports security requirements: SFTP helps organizations meet policies and compliance requirements that require encrypted transfers of sensitive data.
  • Supports secure remote management: Teams can access and manage files on remote systems without exposing the connection.

Where is it used?

Enterprises use SFTP to securely transfer files between internal teams, applications, and storage environments. IT teams rely on it for file-related server administration tasks, such as uploading files, retrieving backups, and managing remote files.

Managed hosting environments commonly support SFTP to give users secure access to website or application files. Businesses also use SFTP to exchange data with external partners and vendors over encrypted connections.

Many organizations integrate SFTP into internal workflows to automate file transfers between systems, cloud services, and external endpoints.

Risks and privacy concerns

While SFTP is designed to be secure, its effectiveness depends on proper configuration and management. Key vulnerabilities include:

  • Server misconfiguration: Incorrect permissions, open directories, or poor server setup can unintentionally reveal sensitive files or access points.
  • Outdated SSH implementations: Vulnerabilities can affect SSH implementations, extensions, or enabled algorithms. Administrators should keep SSH servers and SFTP clients up to date, enable available mitigations, and disable weak or vulnerable algorithms where recommended.
  • Weak credentials: Even with encryption, attackers can exploit weak or reused credentials to gain unauthorized access.
  • Poor key management: SSH keys must be properly generated, stored, and revoked. Unmanaged or shared keys can allow persistent unauthorized access.
  • Insufficient logging: Without proper monitoring and logging, suspicious activity may go unnoticed, delaying incident response.
  • Unprotected data at rest: SFTP encrypts data in transit, but files stored on the server are not automatically encrypted. Separate protections, such as storage encryption and access controls, are needed.

Further reading

FAQ

What is the difference between SFTP and FTPS?

Secure File Transfer Protocol (SFTP) runs over Secure Shell (SSH) and uses a single encrypted connection for both commands and data. File Transfer Protocol Secure (FTPS), on the other hand, is File Transfer Protocol (FTP) secured with Transport Layer Security (TLS) and typically uses separate channels for control and data. They are different protocols and are not interchangeable.

Is Secure File Transfer Protocol more secure than FTP?

Yes. Secure File Transfer Protocol (SFTP) runs over Secure Shell (SSH), which protects authentication and file data in transit, while standard File Transfer Protocol (FTP) can send passwords and other information in clear text. This makes FTP more vulnerable to interception and credential theft.

Does Secure File Transfer Protocol use SSH?

Yes. Secure File Transfer Protocol (SFTP) runs over Secure Shell (SSH) and typically operates as an SSH subsystem, using the SSH connection to secure file transfers.

When should businesses use Secure File Transfer Protocol?

Businesses should use Secure File Transfer Protocol (SFTP) when transferring sensitive or confidential data, working with remote servers, or meeting security requirements that require encrypted file transfers.
Get Started