Skip to main content
All CollectionsAdministering Server and WebsiteConnecting to Application Remotely
Guide to Connecting to Your Application Using SSH/SFTP
Guide to Connecting to Your Application Using SSH/SFTP

[Video Tutorial] Learn how to connect your application using SSH and SFTP on Cloudways.

Usama Zafar avatar
Written by Usama Zafar
Updated over a month ago

Table of Contents

There are different ways to connect to your application remotely, some more secure than others. Two secure methods that we like to use ourselves are Secure Shell (SSH) and Secure File Transfer Protocol (SFTP). Both methods are supported across all our server plans on Cloudways Flexible and Cloudways Autonomous.

What is SSH?

Secure Shell provides strong authentication and encrypted data communications between two computers or servers connecting over an open network such as the Internet. This means that any device in the middle cannot decipher the communication because only your end device/server can decrypt the information exchange.

Tip

You can also run additional tools such as Composer, Git, WP-CLI for WordPress, and database queries using SSH.

What is SFTP?

SFTP stands for Secure File Transfer Protocol (also known as SSH File Transfer Protocol). It is a file transfer protocol such as FTP yet operates over a secure network protocol like SSH. We highly recommend using SFTP for file transferring because:

  • It adds a layer of security.

  • Transferred data is encrypted, so it is not sent in clear text.

How to Connect to Your Application Using SSH/SFTP

First of all, please select your platform:

Cloudways Flexible

Prerequisites

To connect to your server or application using SSH or SFTP, you will need the following:

  1. Public IP address (also known as Server IP)

We will help you locate this information on your Cloudways Platform in the next steps. Please note that the Master user has SSH access enabled by default; however, you must manually enable SSH access for the application user(s).

Video Tutorial — How to Connect via SSH or SFTP on Windows

Step #1 — Accessing the Credentials

There are two types of credentials (Master credentials and Application credentials) on the Cloudways Platform that you can use to connect to your application. Usually, team members are provided with application credentials by the website owner. So, which credentials will you be using?

Important

  • If you are using Microsoft Windows, you must enable WLS (Windows Linux Subsystem) or use a free third-party tool such as PuTTY. Alternatively, you can also use the built-in SSH Terminal of Cloudways Platform.

  • You need an SFTP client to connect to your server remotely. In this demonstration, we are using a free third-party tool called FileZilla, available on Windows and macOS, but you can also use any other client. Please download such tools only from their official website to always get the latest available version.

Using Master Credentials

Log in to your Cloudways Platform using your email address and password.

  1. From the top menu bar, open Servers.

  2. Then, choose the server you wish to connect to.

    Classic Interface

    New Interface

  3. Under Server Management, you can find your Public IP address, username, and password. Be sure to take note of it.

    Tip

    Click on credentials to copy it on the clipboard.

    Classic Interface

    New Interface

Using Application Credentials

Log in to your Cloudways Platform using your email address and password.

  1. From the top menu bar, open Servers.

  2. Then, choose the server where your desired application is deployed to view application credentials.

    Classic Interface

    New Interface

  3. Next, click www. For New Interface, please click the globe icon.

  4. Choose your desired application’s name.

    Classic Interface

    New Interface

  5. Under Application Credentials, you can find your Public IP address, application username, and password. Be sure to take note of it. For New Interface, please navigate to SSH/SFTP tab.

    Tip

    Classic Interface

    New Interface

Below, you will find information about initiating connections using SSH and SFTP separately.

SSH (Microsoft Windows) — Initiating Connection

  1. Launch the PuTTY client and enter your Host Name (Server Public IP address).

  2. Input Port 22, which is also the standard TCP port for SSH.

  3. Click Open.

  4. You may see an RSA2 key prompt if this is your first time connecting to the server. Click Yes to make this a trusted host for future connections.

SSH (Microsoft Windows) — Logging in to Server

  1. You need to input your master or application username, which you previously noted.

    Tip

    • To paste the copied item in the terminal, tap right-click once.

    • The terminal screen will only work with arrow keys for navigation, not with a mouse.

  2. Next, input your password. Please note that no character will appear as you type the password due to security reasons.

  3. You are now connected to your server via SSH. Now, you can run commands such as ls to list and navigate your files and directories.

    Important

    If you are using the Master Credentials, you will need to browse to your target application folder. If you are using the Application Credentials, you will land directly in the respective application folder.

SSH (Linux/macOS) — Logging in to Server

We won’t require any external SSH client for Linux/macOS, although you are free to do so if you already have some preferred 3rd party application. In this example, we are using Linux (Ubuntu).

  1. Open your terminal and execute the following command. A username refers to a master username or application username, and the hostname is your Server Public IP address. By default, the SSH connection is initiated using port 22.

ssh username@host

Example: ssh [email protected]

Note: you can also point your SSH client to which private key should be used by using the -i identity switch as follows:

ssh -i ~/.ssh/id_rsa [email protected]

Tip

  • The terminal screen will only work with arrow keys for navigation, not with a mouse.

2. You may see an RSA key prompt if this is your first time connecting to the server. Type yes to make this a trusted host for future connections.

3. Next, input your password. Please note that your password will not become visible due to security reasons.

4. You are now connected to your server via SSH. Now, you can run commands such as ls to list and navigate your files and directories.

Important

  • If you are using the Master Credentials, you will need to browse to your target application folder. If you are using the Application Credentials, you will land directly in the respective application folder.

  • SSH is a potent tool, and advanced users use it. Executing wrong instructions may break your website and delete the critical files; therefore, we recommend using it with extra care and always taking a backup of the application you are working on or taking a whole server backup always to restore if needed.

SFTP — Initiating Connection

  1. Launch FileZilla client and enter sftp://server-ip-address in Host. By writing sftp://, you are ensuring that the SFTP connection is formed.

  2. You need to input your master or application username, which you previously noted.

  3. Next, input your password.

  4. Set Port 22.

  5. Finally, click QuickConnect.

6. You are now connected to your server via SFTP. Now, you can drag and drop files and folders between your personal computer and your server.

Important

  • If you are using the Master Credentials, you will need to browse to your target application folder. If you are using the Application Credentials, you will land directly in the respective application folder.

  • If you face any permission-related issues, then you can also reset your file and folder permissions.

Cloudways Autonomous

Prerequisites

To connect to your application using SSH or SFTP, you will need the following:

  1. Application credentials

  2. Host

We will help you locate this information on your Cloudways Platform in the next steps.

Step #1 — Accessing the Credentials

Application credentials are used to connect to an application using SSH/SFTP.

Important

  • If you are using Microsoft Windows, you must enable WLS (Windows Linux Subsystem) or use a free third-party tool such as PuTTY.

  • You need an SFTP client to connect to your application remotely. In this demonstration, we are using a free third-party tool called FileZilla, available on Windows and macOS, but you can also use any other client. Please download such tools only from their official website to always get the latest available version.

Log in to your Cloudways Platform using your email address and password.

  1. From the top menu bar, open Applications.

  2. Then, choose your desired application.

  3. Next, click Manage Access.

  4. Navigate to SSH/SFTP.

  5. Under SSH/SFTP, you can find your host, application username, and password. Be sure to take note of it.

    Tip

    • Click on the copy icon to copy the credentials on the clipboard.

    • You can also create additional application credentials to share with your team besides default credentials.

Below, you will find information about initiating connections using SSH and SFTP separately.

SSH (Microsoft Windows) — Initiating Connection

  1. Launch the PuTTY client and enter your Host Name.

  2. Input Port 22, which is also the standard TCP port for SSH.

  3. Click Open.

  4. You may see an RSA2 key prompt if this is your first time connecting to the application. Click Yes to make this a trusted host for future connections.

SSH (Microsoft Windows) — Logging in to Your Application

  1. You need to input your application username, which you previously noted.

    Tip

    • To paste the copied item in the terminal, tap right-click once.

    • The terminal screen will only work with arrow keys for navigation, not with a mouse.

  2. Next, input your password. Please note that no character will appear as you type the password due to security reasons.

  3. You are now connected to your application via SSH. Now, you can run commands such as ls to list and navigate your files and directories.

SSH (Linux/macOS) — Logging in to Your Application

We won’t require any external SSH client for Linux/macOS, although you are free to do so if you already have some preferred third-party application. In this example, we are using Linux (Ubuntu).

  1. Open your terminal and execute the following command. A username refers to an application username. By default, the SSH connection is initiated using port 22.

ssh username@host

Example: ssh [email protected]

Tip

  • The terminal screen will only work with arrow keys for navigation, not with a mouse.

2. You may see an RSA key prompt if this is your first time connecting to the application. Type yes to make this a trusted host for future connections.

3. Next, input your password. Please note that your password will not be visible due to security reasons.

4. You are now connected to your application via SSH. Now, you can run commands such as ls to list and navigate your files and directories.

Important

  • SSH is a potent tool, and advanced users use it. Executing wrong instructions may break your website and delete critical files; therefore, we recommend using it with extra care and always taking a backup of the application to restore it if needed.

SFTP — Initiating Connection

  1. Launch FileZilla client and enter sftp://host in Host. By writing sftp://, you are ensuring that the SFTP connection is formed.

  2. You need to input your application username, which you previously noted.

  3. Next, input your password.

  4. Set Port 22.

  5. Finally, click QuickConnect.

  6. You are now connected to your application via SFTP. Now, you can drag and drop files and folders between your personal computer and your application.

That’s it! We hope this tutorial was helpful. If you need any help, then feel free to search your query on Cloudways Support Center or contact us via chat (Need a Hand > Send us a Message). Alternatively, you can also create a support ticket.


As it is a managed hosting platform, Cloudways removes all your server administration and maintenance hassles, so you remain focused on your business.

Did this answer your question?