> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://help.xynta.com/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# Generating and Using SSH Keys (Windows, macOS, and Linux)

||| ℹ️ **Note:** This article applies to SSH access for Hosting and Managed VPS packages.
---

* [Generate a key in Windows](#3-generate-a-key-in-windows)
* [Use a key in Windows](#3-use-a-key-in-windows)
* [Generate a key in macOS or Linux](#3-generate-a-key-in-macos-or-linux)
---

### Generate a key in Windows

1. [Download](https://www.chiark.greenend.org.uk/~sgtatham/putty/latest.html) and install the **PuTTY program**.
2. Open **PuTTYgen** (Windows > All Programs > PuTTY > PuTTYgen).
3. At the bottom, under **Type of key to generate**, choose **RSA**.
4. Click **Generate** and move your mouse around the window until the progress bar is full.
5. Enter a password of your choice in both the **Key passphrase** and **Confirm passphrase** fields.
6. Click **Save private key** and choose a file name for your SSH key.
7. Right-click the field **Public key for pasting into OpenSSH authorized_keys file**, then click **Select All** and **Copy**.

![](https://storage.crisp.chat/users/helpdesk/website/-/2/6/4/d/264de3e444ab7000/puttygen_ta4a7r.png)
---

### Use a key in Windows

1. [Download](https://www.chiark.greenend.org.uk/~sgtatham/putty/latest.html) and install the **PuTTY program**.
2. Open **PuTTY** (Windows > All Programs > PuTTY).
3. In the left-hand menu under **Connection**, click the plus sign next to **SSH**.
4. Click on **Auth**.
5. Under **Private key file for authentication**, click **Browse** and select your saved SSH key.

The key will now be used automatically when starting an SSH session.

| 📌 **Important:**

Add the public part of your SSH key to your Hosting or Managed VPS package. Also make sure your IP address is added to the firewall whitelist.
---

### Generate a key in macOS or Linux

1. Open **Spotlight** (magnifying glass icon) and search for **Terminal**.
2. Open **Terminal**.
3. Run the following command:

```
ssh-keygen -t rsa
```

4. Press **Enter**.
5. Specify the storage location (press **Enter** to use the default location).
6. Enter a **passphrase** and confirm it.

Although a passphrase is not required, it is strongly recommended.

7. After successful creation, run:

```
cat ~/.ssh/id_rsa.pub
```

This will display the public key, which you need to add to your server or hosting environment.

| 📌 **Important:**

Add the public part of your SSH key to your Hosting or Managed VPS package and make sure your IP address is added to the firewall whitelist.