WeWP
ComparePricingFeaturesContact UsLoginTry For Free
  • Knowledge Base
  • How to Fix "Not Secure" or "Not Private" Connection Errors
  • How to Add Cron Jobs
  • Connect to Your Server via SSH on Windows
  • Keeping Servers and Sites Secure
  • Troubleshooting Cloudflare Issues
  • Install WordPress Themes and Plugins with Composer
  • How To Fix Mixed Content Issue For WordPress
  • What Is a DDoS Attack and How to Prevent It?
  • How to Enable WordPress Debug Mode
  • How to Fix the “MySQL server has gone away” Error
  • How to Configure WP Mail SMTP Plugin to Send Emails
  • How To Fix the “HSTS Missing From HTTPS Server” Error
  • How to Check Your Domain's Expiration Date
  • How to Use and Serve WebP Images in WordPress
  • Email security best practices for using SPF, DKIM, and DMARC
  • What is a LEMP (Linux, Nginx, MySql, PHP) Stack?
  • Deploying Web Applications with NGINX HTTP Server
  • How to Configure WP Rocket Plugin for WordPress
  • How to Check SPF and DKIM Records with WeWP
  • Understanding FTP vs SFTP: Which Should You Use for Secure File Transfers?
  • What is a DMARC record and How to Set it Up?
  • How to Set Up Cloudflare’s Free CDN for WordPress
  • How to check your Ubuntu version (Using the command line and GUI)
  • How to Download Backups from WeWP panel
  • How to Change the PHP Version of Your Hosting Plan
  • Troubleshooting Cloudflare Universal SSL
  • How to Fix “Your Domain Is Not Pointing” Error
  • SSH vs SSL: What’s the Difference?
  • WordPress Search and Replace
  • How to Force HTTPS on WordPress Websites
  • How to Fix a Failed Lifetime SSL Installation
  • How to Redirect HTTP to HTTPS
  • How to Monitor System Processes Using htop Command
  • Varnish vs Nginx FastCGI Cache: Which is Best for WordPress?
  • What Is the Database information_schema on phpMyAdmin?
  • How to Disable WP-Cron for Faster Performance
  • How to fix the ERR_SSL_PROTOCOL_ERROR
  • How to fix the NET::ERR_CERT_AUTHORITY_INVALID error
  • How to Add Expires Headers in WordPress
  • How to fix the “There has been a critical error on your website” error
  • How to Fix ERR_QUIC_PROTOCOL_ERROR in Chrome Browser
  • What Is Localhost? And How Does It Apply to WordPress?
  • How to Fix a Mixed Content Warning on Your Website
  • How to Fix the "Connection Timed Out" Error in WordPress
Powered by GitBook
On this page
  • What is PuTTY ?
  • Download and Install the PuTTY

Was this helpful?

Connect to Your Server via SSH on Windows

Unlike macOS or Linux-based distributions, Windows does not come with a built-in terminal application that you can use to access an Ubuntu server via SSH, using public/private key authentication. However, you can use an application called PuTTY to generate an SSH key and use it to connect to your server’s command line.

What is PuTTY ?

PuTTY is a free and open-source software application that provides a graphical user interface (GUI) for securely connecting to remote systems over networks. It is primarily used on Windows operating systems to establish SSH, Telnet, and serial connections to other devices such as servers, routers, and switches.

Here are key points about PuTTY:

1. SSH and Telnet Client

Regularly update your server's operating system (OS), web server software (like Apache or Nginx), database server (like MySQL or PostgreSQL), and other software components. Keep these up to date to patch vulnerabilities and ensure optimal security.

2. Key Features:

  • Secure Connections: PuTTY supports various encryption methods (e.g., SSH-2) to ensure secure communication over untrusted networks.

  • Terminal Emulation: PuTTY provides a terminal window where you can execute commands on the remote system as if you were directly logged into it.

  • Serial Console Support: PuTTY can connect to devices with serial ports, useful for managing network equipment and embedded systems.

  • X11 Forwarding: Allows remote graphical applications to be displayed locally when using SSH.

  • Session Management: PuTTY allows saving and loading connection settings for quick and easy access to different systems.

3. PuTTY Tools:

  • PuTTYgen: A key generator tool bundled with PuTTY that allows you to create and manage SSH keys for authentication.

  • PSCP: A command-line tool for securely transferring files between Windows and remote systems using SCP (Secure Copy Protocol).

  • PSFTP: A command-line tool for securely transferring files using SFTP (SSH File Transfer Protocol).

4. User Interface:

  • PuTTY provides a simple and straightforward graphical interface for configuring connections.

  • It allows customization of terminal settings such as font, colors, and window size.

5. Usage:

  • PuTTY is widely used by network administrators, system administrators, and developers for managing and troubleshooting remote systems.

  • It is especially popular in environments where secure access to Linux/Unix servers and networking devices is required from Windows machines.

PuTTY is a versatile and essential tool for anyone who needs to establish secure connections to remote systems from a Windows environment, offering reliable SSH and Telnet capabilities with a user-friendly interface.

Download and Install the PuTTY

1. Use PuTTYgen to Generate Your SSH Key

PuTTY has a bundled PuTTYgen application that allows you to generate your public and private keys. The quickest way to run PuTTYgen on Windows 10 is to click the Start button, type putty, and then select “PuTTYgen” from the results.

2. Choosing a More Secure RSA Key Length in PuTTYgen

On Windows 10, PuTTYgen defaults to generating an RSA key of 2048 bits. For increased security, we recommend increasing this value to 4096.

3. Generate the Key Pair:

Click Generate. PuTTYgen will ask you to move the mouse over a selected area to generate the key.

4. Securing Your SSH Key with a Passphrase in PuTTYgen

Once the key generation has completed, PuTTYgen will populate the “Public key”, the “Key fingerprint”, and the “Key comment” values. At this point, entering and confirming a “Key passphrase” is a good idea. You’ll use the passphrase when you authenticate using this key.

First, click the Save private key button, and store the private key as id_rsa.ppk. You can save this anywhere on the computer, either on your desktop or in your Documents folder. Your private key file should be treated as you would a password and never shared with anyone. If you need someone else to access your server, follow the steps in this doc to create a separate private key for them.

You can also click the Save Public Key button to save the public key to a local file, but this is unnecessary.

5. Add the Public Key to Your WeWP Sudo User

→ Before you can connect to the server, you will need to add the public key you just generated to your server, and then attach it to a sudo user. When adding the public key, use the contents of the PuTTYgen “Public key” text area or use the contents from the public key file if you saved it at the previous step.

6. Connect Using the Private Key

Once you have added your public key to your WeWP server and assigned it to a sudo user, you can set up PuTTY to SSH into the server.

Open PuTTY and enter the server’s IP address in the “Host Name” field. If you have already configured your DNS and the domain name is pointing to the server, you can use that here.

7. Configuring SSH Authentication in PuTTY for Secure Connection

Then, navigate to Connection > SSH > Auth under the “Category” tree on the left-hand side of the PuTTY screen.

Click the Browse button, and select the id_rsa.ppk file you saved from PuTTYgen. You can then click Open to start the SSH session, which opens a terminal window.

8. Configuring SSH Authentication in PuTTY for Secure Connection

PuTTY will ask you to confirm if you would like to cache the server’s host key to your local registry. If you click Accept, the next time you connect, you won’t be asked this question again.

9. Logging into Your Server with PuTTY using SSH Key Authentication

You will be asked to enter the sudo user’s username to log into the server and the passphrase for the public key you specified at the generation step. If everything is configured correctly, you will successfully log into your server.

PreviousHow to Add Cron JobsNextKeeping Servers and Sites Secure

Last updated 1 year ago

Was this helpful?

To get PuTTY, browse this link and download and install the latest version.

https://www.chiark.greenend.org.uk/~sgtatham/putty/latest.html