How to Log In to an SFTP Server

How to Log In to an SFTP Server

SFTP stands for Secure File Transfer Protocol. It lets you securely upload, download, and manage files on a remote server.

You usually need:

Info
Server address: sftp.example.com
Username: exampleuser
Password or SSH private key
Port: usually 22


Option 1: Log in with FileZilla

1. Install FileZilla

Download and install FileZilla Client.

2. Open FileZilla

At the top of the window, fill in:

Info
FieldExample
Hostsftp://sftp.example.com
Usernameyour_username
Passwordyour_password
Port22

Make sure the host starts with:

Info
sftp://

Example:

Info
sftp://files.seven-labs.com

3. Click Quickconnect

Click Quickconnect.

The first time you connect, FileZilla may ask you to trust the server’s host key.

Click OK only if you trust the server.

4. Upload or download files

After logging in:

Info
Left side = your computer
Right side = SFTP server

To upload a file, drag it from the left side to the right side.

To download a file, drag it from the right side to the left side.


Option 2: Log in with WinSCP

1. Install WinSCP

Download and install WinSCP.

2. Create a new connection

Open WinSCP and enter:

Info
Setting
Value
File protocolSFTP
Host namesftp.example.com
Port number22
User nameyour_username
Passwordyour_password

3. Click Login

Click Login.

If prompted about the server key, confirm it only if you trust the server.

4. Transfer files

  • WinSCP shows:
Info
Left side = your computer
Right side = server

Drag and drop files to upload or download.


Option 3: Log in from Windows Terminal, PowerShell, macOS, or Linux

Most modern systems include the sftp command.

Use this command:

Info
sftp username@sftp.example.com

Example:

Info
sftp sam@files.seven-labs.com

If the server uses a custom port:

Info
sftp -P 2222 username@sftp.example.com

Example:

Info
sftp -P 2222 sam@files.seven-labs.com

Enter your password when prompted.


Common SFTP Commands

Once logged in, you can use these commands:

CommandDescriptionExample
lsLists files on the server.ls
pwdShows your current folder on the server.pwd
cdChanges folders on the server.cd uploads
put filename.txtUploads a file to the server.put document.txt
get filename.txtDownloads a file from the server.get backup.zip
mkdirCreates a folder on the server.mkdir newfolder
rmDeletes a file from the server.rm oldfile.txt
exitDisconnects from the SFTP server.exit

Example Login

Info
sftp myuser@sftp.example.com

Then upload a file:

Info
put report.pdf

Then disconnect:

Info
exit

Troubleshooting

Permission denied

Check that your username and password are correct.

Connection timed out

The server may be offline, the address may be wrong, or a firewall may be blocking the connection.

Wrong port

SFTP usually uses port 22, but some servers use a custom port like 2222.

Cannot upload files

Your account may not have write permissions to that folder. Try uploading to your home directory or contact the server administrator.



Warning
Security Tips
Use SFTP instead of plain FTP whenever possible.
Never share your password publicly.
Only accept a server host key if you trust the server.
Use an SSH key instead of a password when possible.