scp command

Generate SCP commands for uploads, downloads, and recursive folder transfers

Build ready-to-run scp commands for moving files between your machine and a remote server, including custom ports, key files, and jump hosts.

Choose a transfer mode, fill in the source and destination, and copy the exact command.

Transfer mode

Send a file from your machine to the remote server over SSH.

Transfer details

Generated command

Copy the command and run it in Terminal.

scp -P 22 -i ~/.ssh/id_ed25519 ~/Downloads/report.csv ubuntu@server.example.com:~/deploy/report.csv

After the file transfer command is ready, keep the rest of the workflow in DartShell

Manage SSH sessions, file transfer, and database access in one Mac workspace after the copy step is done.

Related tools

SSH keygen command generator

Create the identity file you are about to pass to scp -i.

SSH config example generator

Store the host, port, and bastion settings you keep retyping in one Host alias.

SSH port forwarding generator

Open a tunnel when the service you are copying for is not reachable directly.

What this SCP tool helps with

Move files without remembering flags

When you only need a quick secure copy, this tool helps you build the right scp command without re-checking syntax.

Handle ports, keys, and bastions

You can include the SSH port, identity file, and jump host settings that often show up in production environments.

Copy directories safely

Recursive mode is useful for build artifacts, configuration folders, and one-off backup transfers.

Common SCP examples on macOS

Upload a file from your Mac to a server

scp -i ~/.ssh/id_ed25519 ~/Downloads/report.csv ubuntu@server.example.com:~/deploy/report.csv

The local path comes first. The -i flag points at the private key stored on your Mac; quote the path if it contains spaces.

Download a file from a server to your Mac

scp -i ~/.ssh/id_ed25519 ubuntu@server.example.com:/var/log/app.log ~/Downloads/app.log

Reverse the order: remote source first, local destination last. The tilde is expanded by your shell on macOS.

Copy an entire folder to a server

scp -r -i ~/.ssh/id_ed25519 ./dist ubuntu@server.example.com:~/releases/dist

The -r flag copies the folder and everything beneath it, which is useful for build output and static assets.

Download an entire folder to your Mac

scp -r -i ~/.ssh/id_ed25519 ubuntu@server.example.com:~/backups/2026-11 ~/Downloads/backups

Keep -r before both paths so the whole remote tree comes down in one command.

Use a custom SSH port and key file

scp -P 2222 -i ~/.ssh/id_ed25519 ./app.tar.gz deploy@server.example.com:~/app.tar.gz

scp uses uppercase -P for the port. Lowercase -p preserves file timestamps instead, so the two are easy to mix up.

Copy through a jump host

scp -o "ProxyJump=bastion-gateway" -i ~/.ssh/id_ed25519 ./config.yml deploy@10.0.1.24:~/config.yml

Use this when the server is only reachable through a bastion. The generator above can add this setting for you.