DEV Community

Dênis Mendes
Dênis Mendes

Posted on • Edited on

2 1

Connect to SFTP server using command line on macOS

Hi there!

It's here how I connect to sftp server using only command line tool from macOS:

sftp -P replace_with_server_port -i replace_with_your_ssh_private_file replace_with_server_username@replace_with_server_host

Maybe you will be asked about password you set for ssh private key:

Enter passphrase for key '.ssh/ssh_private_file_path':

And then after you type the password you will see that:

Connected to server_host:
sftp>
Enter fullscreen mode Exit fullscreen mode

It's done! You're in.

Now if you want to send a file you need to type:

sftp> put your_file_name_with_extension

Top comments (0)

👋 Kindness is contagious

Dive into an ocean of knowledge with this thought-provoking post, revered deeply within the supportive DEV Community. Developers of all levels are welcome to join and enhance our collective intelligence.

Saying a simple "thank you" can brighten someone's day. Share your gratitude in the comments below!

On DEV, sharing ideas eases our path and fortifies our community connections. Found this helpful? Sending a quick thanks to the author can be profoundly valued.

Okay