Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more

For most Linux VPS users, SFTP over SSH is the best default. It encrypts both your credentials and file data, uses the SSH access your server already needs, and works from either a terminal or a graphical client such as FileZilla. Use scp when you need a quick one-off copy, rsync over SSH for recurring deployments or directory synchronization, and plain FTP only when you have a specific legacy requirement and have separately protected the connection.

This guide shows how each method works, how to set up key-based access, which command or interface to choose, and how to recover from the most common transfer failures.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Choose the transfer method that fits the job

The right tool depends less on raw speed than on how you work. The documented tools all use SSH except traditional FTP, so the deciding factors are interactivity, repeatability, directory handling, and whether you prefer a graphical or terminal workflow.

Method Security and authentication Best fit Directory and transfer behavior Interface
SFTP Encrypted SSH transport; uses the same SSH authentication methods General-purpose uploads, downloads, and browsing Interactive file management, recursive transfers, resume attempts, permission and timestamp preservation, and bandwidth limiting are documented by current Ubuntu OpenSSH documentation Terminal or a graphical SFTP client
scp SSH data transfer and SSH login authentication A few files or a single one-off directory copy Recursive copying is available with -r; the cited guidance does not specify resume or metadata controls Terminal
rsync over SSH SSH encryption and authentication Repeated deployments and synchronizing directory trees In a typical rsync workflow, only changed data is sent; detailed feature behavior depends on the options you select Terminal and scripts
FileZilla using SFTP SFTP over SSH with a password or private key People who prefer a visual file manager Uses the SFTP protocol while presenting local and remote panes for transfers Graphical
Plain FTP FTP does not encrypt credentials or transferred data Legacy systems only, after a separate security review Its unencrypted transport makes it unsuitable for ordinary VPS administration Graphical or terminal

DigitalOcean’s transfer documentation, last verified 13 July 2026, recommends SFTP with FileZilla for newer users and lists rsync, OpenSSH sftp, and scp for command-line users. Ubuntu’s current SFTP manpage describes SFTP as performing all operations over an encrypted ssh(1) transport.

Why SFTP is the safest default

SFTP is an interactive file-transfer program built on SSH. The same server daemon that accepts your normal SSH login carries the file operation, so you do not have to expose a separate FTP service or create a second set of credentials. Encryption covers the login exchange, commands, directory listings, and file contents while they travel between your computer and the VPS.

Once connected, you can browse directories, create or remove remote directories, upload with put, download with get, and transfer trees recursively. Current Ubuntu documentation also describes attempts to resume interrupted transfers, preservation of permissions and timestamps, and bandwidth limiting. Those behaviors can still depend on the client and the options you use, so verify the result when metadata matters.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Prepare SSH access before transferring anything

File-transfer tools cannot fix a broken SSH login. Establish a working, least-privilege SSH account first, then use that account for SFTP, SCP, or rsync.

1. Confirm the required software

The VPS needs an SSH server, and your local computer needs an OpenSSH client. On Ubuntu, the relevant packages are commonly provided as openssh-server on the VPS and openssh-client on the local machine. Your distribution may use different package names, but the requirement is the same: an SSH daemon listening on the server and an SSH client available locally.

Test the service with a normal login before attempting a transfer:

ssh user@vps.example

Replace user with the account that owns the destination directory and replace vps.example with your VPS hostname or address. If the command cannot connect, resolve that issue first rather than changing transfer tools.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

2. Generate an Ed25519 key pair

On your local machine, create a key pair with:

ssh-keygen -t ed25519

Ubuntu recommends Ed25519 because its key is shorter and requires less computation than older key types. Accept the default path if you do not already have a key there, and use a passphrase whenever practical. The private key stays on your computer; the public key is the one installed on the VPS.

3. Install the public key on the VPS account

If password-based SSH login is currently enabled, DigitalOcean documents ssh-copy-id as a way to install the public key for an existing server account:

ssh-copy-id -i ~/.ssh/id_ed25519.pub user@vps.example

You can also add the public-key text to the account’s ~/.ssh/authorized_keys file through an existing administrative session. Ensure that the account owns its .ssh directory and authorized_keys file and that their permissions do not allow other users to modify them.

4. Test key-based login

Log in explicitly with the private key:

ssh -i ~/.ssh/id_ed25519 user@vps.example

Only after this succeeds should you move to file transfer. Keep the private key confidential and never upload it to the VPS as a way to “make transfers work.”

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Use SFTP from the terminal

Start a session

Connect with the same key used for SSH:

sftp -i ~/.ssh/id_ed25519 user@vps.example

You will see an sftp> prompt after authentication. The local working directory is the directory from which you launched SFTP; the remote working directory is normally the account’s home directory.

Browse local and remote locations

These commands let you orient yourself before copying:

  • pwd prints the current remote directory.
  • lpwd prints the current local directory.
  • ls lists the remote directory.
  • lls lists the local directory.
  • cd /remote/path changes the remote directory.
  • lcd /local/path changes the local directory.
  • mkdir directory-name creates a remote directory when your account has permission.

Using absolute paths is safer for scripted or high-impact work because it avoids confusion about which side of the connection a relative path refers to.

Upload files and directories

To upload a single local file to the current remote directory:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
put local-file /remote/path/

For example:

put ./backup.tar.gz /srv/backups/

Use recursive mode for a directory tree:

put -r ./site /var/www/

Check ownership and permissions on the destination afterward. A successful transfer only means the SFTP account could write the bytes; it does not guarantee that a web server, application service, or another Linux user can read them.

Download files and directories

Download a remote file with:

get /remote/path/report.csv ./downloads/

For a directory tree, use recursive mode:

get -r /var/www/site ./site-copy

Before downloading a large tree, use pwd and lpwd to confirm that the destination is the one you intended.

Handle interruptions and metadata deliberately

Current Ubuntu SFTP documentation describes resume attempts, permission and timestamp preservation, recursive transfers, and bandwidth limiting. Client support and command-line options vary, so inspect the local SFTP help with:

help

If a transfer is interrupted, retry it rather than assuming that a partially written file is complete. For deployments, compare file sizes or checksums using a separate verification step appropriate to your application. If preserving ownership, modes, or timestamps is essential, verify those attributes on the VPS after the transfer; the account must have permission to set them.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Use SCP for a quick one-off copy

scp is simpler than an interactive SFTP session when you already know the source and destination. Ubuntu describes it as copying files between hosts using SSH for data transfer and the same authentication used for an SSH login.

Copy one local file to the VPS

scp -i ~/.ssh/id_ed25519 ./backup.tar.gz user@vps.example:/srv/backups/

The final argument combines the remote account, host, and destination path. Quote paths containing spaces so your local shell does not split them into separate arguments.

Copy a file from the VPS to your computer

scp -i ~/.ssh/id_ed25519 user@vps.example:/srv/backups/backup.tar.gz ./downloads/

Copy a directory recursively

scp -r -i ~/.ssh/id_ed25519 ./site user@vps.example:/var/www/

Use SCP when the operation is short and deterministic. For a large transfer that may need recovery, an interactive SFTP client or an rsync workflow is easier to inspect and repeat. The cited SCP guidance does not define a resume feature or a comprehensive metadata-preservation policy, so do not assume either behavior without checking your installed client.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Use rsync over SSH for repeat deployments

Rsync is suited to a directory that changes repeatedly: application releases, backups, documentation, or a working tree that must be mirrored to the VPS. In a typical rsync workflow, only changed data needs to be sent, which avoids retransmitting files that are already synchronized.

Synchronize a local directory to the VPS

rsync -avz -e "ssh -i ~/.ssh/id_ed25519" ./site/ user@vps.example:/var/www/site/

The trailing slash on ./site/ means “the contents of this directory.” Removing it changes the resulting directory layout. The example uses common rsync options for archive-style handling, compression, and an explicit SSH command; review the rsync manpage on your system before relying on any option for a production deployment.

Preview changes before applying them

For a deployment or synchronization job, perform a dry run first:

rsync -avzn -e "ssh -i ~/.ssh/id_ed25519" ./site/ user@vps.example:/var/www/site/

Read the proposed file list and confirm the remote path. A typo in the destination can place a correct copy in the wrong directory, while an overly broad deletion option can remove data you meant to retain. Add destructive options only after you understand their effect and have a recoverable backup.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Automate carefully

Rsync can be called from deployment scripts or scheduled jobs, but unattended jobs create a security trade-off. A passphrase-protected key is safer for people, while automation needs a way to unlock credentials. Restrict an automation account to the directory and commands it actually needs, log each run, and test restoration rather than assuming that a successful synchronization is a usable backup.

DigitalOcean lists rsync as a command-line transfer option, but its cited documentation does not publish a detailed rsync feature specification or a controlled speed comparison. Choose it for repeatability and changed-data synchronization, not for an unsupported promise of a particular transfer rate.

Transfer files with FileZilla over SFTP

FileZilla is a free, open-source, cross-platform graphical client. DigitalOcean recommends it with SFTP for newer users. It gives you a local pane and a remote pane, so you can drag files without memorizing shell commands while retaining SSH encryption.

Configure the connection

  1. Open FileZilla and open File > Site Manager.
  2. Create a new site entry and set Protocol to SFTP – SSH File Transfer Protocol. Do not select plain FTP for a secure VPS transfer.
  3. Enter the VPS host name or address, SSH port, and account name. Use the port configured by your server rather than assuming the default.
  4. Choose the key-file authentication option and add the private key corresponding to the public key installed on the VPS. If FileZilla requests a key format conversion, confirm that you are converting a copy and keep the original private key protected.
  5. Save the entry and connect. Verify the server’s host-key prompt through a trusted administration channel before accepting it; a changed key can indicate a rebuilt server or a man-in-the-middle risk.

Upload and download

The left pane shows local files and the right pane shows the remote directory. Navigate to the intended folders, then drag files or directories between panes. Watch the transfer queue for failures instead of closing the program immediately. For a failed item, read the status message, correct the permission or path problem, and retry. Confirm the resulting owner, mode, and application behavior on the VPS.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

When a GUI is preferable

FileZilla is useful when you need to browse unfamiliar directories, move mixed groups of files, or teach a teammate a repeatable visual workflow. Terminal SFTP remains easier to document in a runbook and to reproduce exactly, while rsync is better when the same directory must be synchronized frequently.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Why plain FTP is a poor VPS choice

Traditional FTP sends credentials and transferred data without encryption. Anyone able to observe the connection can potentially read the login exchange or file contents, and the protocol introduces a separate service that must be configured and protected. Ubuntu’s FTP documentation explicitly directs users who need secure transfer to SFTP in the OpenSSH-Server documentation.

Do not “secure” ordinary FTP by merely placing it next to an SSH service. Use SFTP, SCP, or rsync over SSH instead. If a legacy application absolutely requires FTP, isolate it, restrict network access, and obtain a security design appropriate to that application; that is a different project from routine VPS file transfer.

Security practices that prevent avoidable incidents

  • Use key authentication. Prefer an Ed25519 key with a passphrase, and install only the public key on the VPS.
  • Protect the private key. Store it locally, limit file permissions, and never paste it into a ticket, script repository, or server directory.
  • Use a dedicated account. Give the transfer account access to the required destination instead of routinely transferring as the root user.
  • Verify the host key. An unexpected fingerprint change deserves investigation before you log in.
  • Limit network exposure. Allow SSH only from the administrative networks or addresses your environment requires, where practical.
  • Check destination permissions. A transfer can succeed while the service that needs the file remains unable to read it.
  • Keep an independent backup. Synchronization is not the same as a recoverable backup, especially when a deletion propagates to the remote side.

Troubleshoot the failures you are most likely to see

“Connection refused” or a timeout

Confirm that the VPS is running its SSH server, that you are using the correct host and port, and that the firewall or security group permits that port from your current network. Test with ordinary ssh; changing from SFTP to SCP will not repair a network-level failure.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

“Permission denied” during upload

First identify whether authentication failed or the remote path is unwritable. Log in with SSH, run pwd, inspect the destination directory, and check its owner and mode. Upload to a directory your account owns, then move the file with an administrative action only when that is part of your server’s documented deployment process.

“No such file or directory”

Remote and local paths are separate. In SFTP, use pwd and lpwd; in SCP and rsync, re-read the complete source and destination arguments. Check capitalization because Linux paths are case-sensitive.

The transfer stops partway through

Check the local and VPS disk space, network stability, and any connection idle timeout. Retry with SFTP, which documents resume attempts, or rerun rsync for a synchronization workflow. Treat a partial file as untrusted until you verify its size, checksum, or application-specific integrity.

The file arrives but the application cannot use it

Inspect ownership, permissions, SELinux or other mandatory-access-control messages where applicable, line endings for text configuration, and the application’s expected directory. A file’s successful arrival does not automatically reload a service or make it executable.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

FileZilla cannot load the key

Confirm that the selected protocol is SFTP, that the key belongs to the public key installed for the account, and that the local key file is readable by your user. If the client requires a converted format, preserve the original and use a separate copy. Test the same key with ssh -i to distinguish a client configuration issue from a server authentication issue.

A practical decision checklist

  1. One or two known files: use SCP with an explicit destination.
  2. Browsing, mixed uploads and downloads, or manual recovery: use SFTP.
  3. Repeated releases or a changing directory tree: use rsync over SSH and preview changes before applying them.
  4. No command-line comfort: use FileZilla configured for SFTP, not plain FTP.
  5. Security-sensitive data: use SFTP, SCP, or rsync over SSH with key authentication and a protected private key.

OpenSSH’s purpose is to provide encrypted remote control and file-transfer tools that replace legacy, insecure utilities. For a Linux VPS, that makes SSH-based transfer the coherent default: one hardened access path, one authentication model, and a method chosen according to whether you need browsing, a one-time copy, synchronization, or a graphical interface.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.