Secure copy files on VPS or dedicated server with SCP

Most of the time if you are using a VPS hosting server or own dedicated server you will need to copy a single file, group of files or whole folder to another remove VPS or dedicated server. You can use the old good one FTP way just when uploading files to the remote server. But there is a lot easier and secure way to transfer files between servers with SCP (Secure Copy Program).

When you like to copy a single file from one VPS or dedicated server to another one you can use the following SSH command:

scp file.tar [email protected]:/your/directory/

To copy a whole folder between servers you can run the following SSH command:

scp -r folder [email protected]:/your/directory/

When using SCP the server will ask you for the password for the username on the new VPS hosting server or dedicated server (unless you have setup trust between servers with authentication keys). If you like to see all of the command options from shell just type "man scp" in the VPS or dedicated server SSH console. This SSH command will show you the SCP manual with all options you can use like changing server ports and more SCP parameters.

To use SCP you need to have on your VPS hosting server or dedicated server Shell (SSH) access enabled.

  • 52 Users Found This Useful
Was this answer helpful?

Related Articles

Buy web hosting with Payeer

Payeer is a payment platform that makes it easy to pay for products and services on different...

Buy web hosting with dogecoin

Buy web hosting with dogecoin What is web hosting? For amateurs, web hosting may seem to be all...

Buy web hosting with bank wire

Web Hosting with Bank Wire When you need a quick and secure way to pay for goods and services, a...

VPS hosting advantages

The VPS hosting gives you the functionality and options of the dedicated server, but at a much...

Buy web hosting with ClickAndBuy

Web hosting with ClickandBuy Individuals and organizations can host their own websites as long...