How to Install PuTTy on Ubuntu Linux

PuTTY is a trusted SSH client that makes managing remote servers simple and secure. Lightweight and versatile, it is ideal for tasks such as connecting to servers, transferring files, and generating SSH keys. While primarily used for secure shell (SSH) connections, PuTTY also supports Telnet, rlogin, and raw TCP, making it a valuable tool for a variety of networking tasks.

This guide walks you through installing PuTTY on Ubuntu. Additionally, you will learn how to install PuTTY and its companion tools, launch the graphical interface for SSH connections, use PuTTY’s secure file transfer utility (PSCP), and generate SSH keys with PuTTYgen. While Ubuntu ships with OpenSSH by default, PuTTY offers a familiar graphical interface for users transitioning from Windows, supports saved session profiles, and handles PuTTY’s native PPK key format for compatibility with existing Windows-based workflows.

Choose Your PuTTY Installation Method

Ubuntu offers two ways to install PuTTY: through the default APT package manager or via Flatpak for sandboxed deployment. Generally, most users should install from Ubuntu’s repositories for simplicity and automatic system updates, while Flatpak provides isolation and works across all Linux distributions.

MethodChannelReleaseUpdatesBest For
APTUbuntu ReposStableAutomatic via apt upgradeMost users, system integration
FlatpakFlathubLatestAutomatic via FlatpakSandboxed environment, cross-distro

This guide documents both methods with complete step-by-step instructions. Ultimately, choose APT for traditional system integration or Flatpak for sandboxed deployment and automatic updates independent of Ubuntu releases.

Update Ubuntu Before PuTTY Installation

Before installing PuTTY, first update your system to ensure you have the latest security patches and package definitions. To begin, open a terminal by pressing Ctrl + Alt + T and run the following command:

sudo apt update && sudo apt upgrade

If prompted, type y and press Enter to confirm package upgrades. Afterward, restart your system if kernel updates are installed to ensure all changes take effect.

Install PuTTY via APT Command

Installing PuTTY on Ubuntu is straightforward thanks to the APT package manager, which pulls software directly from Ubuntu’s trusted repositories. As a result, this ensures that PuTTY is secure, stable, and easy to install. Follow these steps to set up PuTTY on your system:

Step 1: Install PuTTY Using APT

To begin the installation process, open your terminal and enter the following command:

sudo apt install putty putty-tools

This command installs:

  • PuTTY: The core application for establishing SSH connections and managing remote servers.
  • PuTTY Tools: Additionally, a suite of utilities, including PuTTYgen for generating SSH keys and PSCP for transferring files securely.

During installation, APT will automatically handle dependencies. Subsequently, if prompted to confirm, type y and press Enter.

Step 2: Verify the Installation

Once the installation completes, verify that PuTTY is available on your system by checking the installed version:

apt-cache policy putty

Expected output showing the installed version:

putty:
  Installed: 0.8x-x
  Candidate: 0.8x-x
  Version table:
 *** 0.8x-x 500
        500 http://archive.ubuntu.com/ubuntu /universe amd64 Packages
        100 /var/lib/dpkg/status

The output confirms PuTTY is installed and ready to use. However, version numbers and release names (noble for 24.04, jammy for 22.04) will vary depending on your Ubuntu release.

This guide supports Ubuntu 22.04 LTS and 24.04 LTS installations. Commands shown work identically on both supported LTS releases.

Install PuTTY via Flatpak

Flatpak provides PuTTY in a sandboxed environment with automatic updates independent of Ubuntu release cycles. Consequently, this method works across all Ubuntu versions and future releases without compatibility concerns. If you need comprehensive Flatpak setup instructions, see our Flatpak installation guide for Ubuntu.

Step 1: Install Flatpak Framework

First, install the Flatpak framework if it is not already present on your system:

sudo apt install flatpak

If prompted to confirm, type y and press Enter.

Step 2: Add Flathub Repository

Next, add the Flathub repository, which hosts the official PuTTY Flatpak:

flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo

The --if-not-exists flag prevents errors if Flathub is already configured.

Step 3: Install PuTTY from Flathub

Now, install PuTTY and its tools using the Flatpak application ID:

flatpak install flathub uk.org.greenend.chiark.sgtatham.putty -y

Flatpak will then download PuTTY and any required dependencies automatically.

Step 4: Verify the Flatpak Installation

Once installation completes, verify PuTTY appears in your installed Flatpak applications:

flatpak list --app | grep -i putty

Expected output confirming PuTTY is installed:

PuTTY   uk.org.greenend.chiark.sgtatham.putty   0.8x    stable  system

Typically, the version number will reflect the latest release available on Flathub.

Flatpak applications run in isolated environments and may require additional permissions for filesystem access. Grant permissions through Flatseal or command-line overrides if you need PuTTY to access specific directories for key storage or configuration files.

Launch PuTTY Graphical Interface

After installing PuTTY, you can launch it using either the terminal or the graphical interface, depending on your preference. Specifically, follow the steps below to access PuTTY on your Ubuntu system.

Method 1: Launch PuTTY from the Terminal

For a quick and direct method, open a terminal and enter the following command:

putty

This will immediately launch PuTTY’s graphical user interface (GUI), where you can then configure and initiate SSH or other network connections.

Method 2: Launch PuTTY from the Applications Menu

Alternatively, you can use the graphical menu to open PuTTY:

  • Click on Activities in the top-left corner of your screen.
  • Select Show Applications to view all installed applications.
  • Use the search bar to type PuTTY and locate the PuTTY icon.
  • Click the PuTTY icon to open the application.

PuTTY Interface Overview

Once launched, PuTTY’s interface provides options to:

  • Enter the hostname or IP address of the server you want to connect to.
  • Select the connection type (e.g., SSH, Telnet, or Raw TCP).
  • Customize session settings such as ports, saved sessions, and appearance.

Using PuTTY Command-Line Tools

PuTTY includes command-line utilities for SSH connections, secure file transfers, and SSH key generation. In particular, these tools are particularly useful if you are transitioning from Windows workflows or need PuTTY-specific features like PPK key format support.

Connect to Remote Servers from Terminal

To establish an SSH connection from the command line, use the following syntax:

putty [user@]hostname

Replace user with your username and hostname with the server’s IP address or domain name. For instance:

putty root@192.168.1.100

This launches PuTTY’s graphical terminal and initiates an SSH connection to 192.168.1.100 using the root account.

If you installed PuTTY via Flatpak, launch it from the terminal with flatpak run uk.org.greenend.chiark.sgtatham.putty or find it in your Applications menu. The Flatpak version includes all PuTTY tools (PSCP, PuTTYgen) accessible through the same Flatpak environment.

Transfer Files with PSCP (PuTTY Secure Copy)

The putty-tools package includes PSCP (PuTTY Secure Copy Protocol), which transfers files securely between your local system and remote servers. Additionally, PSCP supports PuTTY’s PPK key format and Windows-style paths, making it useful for cross-platform workflows.

Upload a file to a remote server:

pscp local_file user@host:remote_path

For example, uploading document.txt to the remote server’s /root directory:

pscp /home/user/document.txt root@192.168.1.100:/root/document.txt

Download a file from a remote server:

pscp user@host:remote_file local_path

Similarly, downloading document.txt from the remote server to your local home directory:

pscp root@192.168.1.100:/root/document.txt /home/user/

Ubuntu also ships with OpenSSH’s scp command, which works identically for most file transfer tasks. Use PSCP when you need PuTTY PPK key compatibility or are following existing Windows-based PuTTY workflows.

Generate SSH Keys with PuTTYgen

PuTTYgen generates SSH key pairs in PuTTY’s native PPK format or standard OpenSSH format. To start, launch the graphical interface with:

puttygen

In the GUI, select the key type (RSA recommended, 2048 or 4096 bits), click Generate, and move your mouse randomly to create entropy. Afterward, save both the private key (PPK format) and public key for authentication.

Alternatively, you can also convert an existing OpenSSH private key to PPK format using PuTTYgen from the command line:

puttygen openssh_key -o converted_key.ppk -O private

Most Linux users prefer OpenSSH’s ssh-keygen for key generation, which creates keys in the standard OpenSSH format used by Ubuntu’s native SSH client. Use PuTTYgen when you need PPK format keys for compatibility with Windows PuTTY sessions or when converting between key formats.

Troubleshooting Common PuTTY Issues

If you encounter issues running PuTTY on Ubuntu, the following solutions address the most common problems.

PuTTY GUI Fails to Launch

Error:

(putty:12345): Gtk-WARNING **: cannot open display:

This error occurs when PuTTY cannot access the graphical display, typically in SSH sessions or headless environments. To resolve this, verify you are running PuTTY from a local desktop session with GUI access:

echo $DISPLAY

Expected output showing an active display:

:0

If the output is empty, you are either in a text-only session or connected via SSH without X11 forwarding. In this case, launch PuTTY from a local desktop environment or enable X11 forwarding if connecting remotely.

SSH Connection Refused

Error:

Network error: Connection refused

This indicates the remote server is not accepting SSH connections on the specified port. First, verify the SSH service is running on the remote server and that you are using the correct port (default is 22). Then, test connectivity by attempting a direct connection:

ssh -v root@192.168.1.100

The -v (verbose) flag shows detailed connection information. If SSH times out or refuses the connection, then check firewall rules on both systems and ensure the SSH daemon is active on the remote server. For Ubuntu systems, configure UFW firewall to allow SSH connections.

Authentication Failed with PPK Keys

Error:

PuTTY Fatal Error: Unable to use key file

PuTTY’s PPK key format is not compatible with OpenSSH servers by default. Therefore, convert your PPK key to OpenSSH format using PuTTYgen:

puttygen mykey.ppk -O private-openssh -o mykey_openssh

Afterward, use the converted key with standard SSH or specify the PPK key in PuTTY’s GUI under Connection → SSH → Auth → Private key file.

Remove PuTTY from Ubuntu

If you no longer need PuTTY on your Ubuntu system, you can remove it along with its associated tools using the APT package manager. Specifically, follow these steps to uninstall PuTTY safely and clean up your system.

Step 1: Open the Terminal

Press Ctrl + Alt + T or search for Terminal in your applications menu to open a terminal window.

Step 2: Remove PuTTY and Its Tools

Run the following command to uninstall PuTTY and its additional tools:

sudo apt remove putty putty-tools

This command removes the core PuTTY application and related utilities such as PuTTYgen and PSCP.

Step 3: (Optional) Remove Configuration Files

If you also want to delete PuTTY’s configuration files, use the following command:

sudo apt purge putty putty-tools

Using the purge option will permanently remove PuTTY’s configuration files, including any saved sessions and preferences. This action cannot be undone.

Step 4: Clean Up Unused Dependencies

To remove any unnecessary dependencies left behind, run:

sudo apt autoremove

This cleans up your system, consequently reclaiming disk space by deleting packages no longer needed.

Remove PuTTY Flatpak Installation

If you installed PuTTY via Flatpak, remove it with the following command:

flatpak uninstall uk.org.greenend.chiark.sgtatham.putty

Flatpak will prompt for confirmation before removing the application. Additionally, to also remove unused runtimes and dependencies, run:

flatpak uninstall --unused

Conclusion: Managing Remote Connections with PuTTY on Ubuntu

You have successfully installed PuTTY on Ubuntu and learned how to launch the graphical SSH client, transfer files securely with PSCP, and generate SSH keys using PuTTYgen. While Ubuntu’s native OpenSSH client handles most SSH tasks efficiently, PuTTY offers a familiar graphical interface for users transitioning from Windows, supports saved session profiles for quick connections, and provides PPK key format compatibility for existing workflows.

Next, consider configuring saved sessions in PuTTY’s GUI to streamline connections to frequently accessed servers. Furthermore, for enhanced security, set up key-based authentication by generating SSH keys with PuTTYgen and adding your public key to remote servers. Finally, if you work primarily from the terminal, explore PuTTY’s command-line tools like PSCP for scripted file transfers or investigate SSH connection tunneling for secure access to remote services.

6 thoughts on “How to Install PuTTy on Ubuntu Linux”

  1. Good morning, I have the following error

    (putty:49401): Gtk-CRITICAL **: 09:10:26.330: gtk_box_gadget_distribute: assertion ‘size >= 0’ failed in GtkScrollbar

    (putty:49401): Gtk-CRITICAL **: 09:10:26.334: gtk_box_gadget_distribute: assertion ‘size >= 0’ failed in GtkScrollbar

    (putty:49401): Gtk-CRITICAL **: 09:10:26.337: gtk_box_gadget_distribute: assertion ‘size >= 0’ failed in GtkScrollbar

    Reply
    • Thanks for reporting this, ysa. These GTK-CRITICAL warnings about scrollbar distribution are cosmetic rendering messages from PuTTY’s GTK interface. They do not affect PuTTY’s functionality or SSH connections. The warnings appear because PuTTY’s GTK code encounters edge cases with certain scrollbar sizes during window initialization.

      PuTTY should work normally despite these messages. If the application is otherwise functional, you can safely ignore the warnings. They only appear in the terminal you launched PuTTY from, not in PuTTY’s own terminal window. To avoid seeing these warnings, launch PuTTY from your applications menu instead of the command line.

      If PuTTY crashes or fails to display properly, verify your GTK libraries are up to date with sudo apt update && sudo apt upgrade. Alternatively, try the Flatpak version documented in the guide, which bundles its own GTK runtime and avoids conflicts with system libraries.

      Reply
    • Thanks for your comment, Bruno. Serial ports on Linux are restricted to the root user and dialout group by default for security reasons. To allow your user account to access serial devices without root privileges, follow these steps:

      First, add your user to the dialout group:

      sudo usermod -aG dialout $USER

      After running the command, log out completely and log back in for the group membership to take effect. Verify the change with:

      groups

      Expected output showing dialout in your groups:

      username adm cdrom sudo dip plugdev dialout lpadmin

      Next, verify the serial port permissions. Check the device file you want to use:

      ls -l /dev/ttyUSB0

      Expected output showing dialout group ownership:

      crw-rw---- 1 root dialout 188, 0 Dec 26 11:56 /dev/ttyUSB0

      The rw- permissions for the dialout group allow read and write access. Once you are in the dialout group and logged back in, PuTTY will connect to serial ports without requiring root access.

      Reply
        • Thanks for the follow-up, Bruno. Since you are already in the dialout group and Minicom works without root, this points to a PuTTY-specific configuration issue rather than system permissions. Let me walk you through diagnosing this.

          First, verify PuTTY can see the serial device. Launch PuTTY from the terminal to see any error messages:

          putty

          In the PuTTY configuration window, select Serial as the connection type and enter your serial port path (for example, /dev/ttyUSB0). If PuTTY shows a permissions error in the terminal when you click Open, run this command to check the exact device permissions:

          ls -l /dev/ttyUSB0
          id

          Expected output confirming group membership and permissions:

          crw-rw---- 1 root dialout 188, 0 Jun 21 20:46 /dev/ttyUSB0
          uid=1000(bruno) gid=1000(bruno) groups=1000(bruno),20(dialout),27(sudo)

          If the output shows you are in the dialout group but PuTTY still fails, this is typically caused by one of three issues. First, some Ubuntu systems have AppArmor or SELinux policies that restrict PuTTY specifically. Check if AppArmor is blocking PuTTY:

          sudo aa-status | grep putty

          If PuTTY appears in the output, temporarily disable the AppArmor profile to test:

          sudo aa-complain /usr/bin/putty

          Second, verify the serial device node has correct permissions. Some systems recreate device nodes with restrictive permissions on boot. If ls -l /dev/ttyUSB0 shows anything other than crw-rw---- with dialout group, create a udev rule to fix permissions permanently:

          echo 'KERNEL=="ttyUSB[0-9]*", MODE="0660", GROUP="dialout"' | sudo tee /etc/udev/rules.d/50-serial.rules
          sudo udevadm control --reload-rules
          sudo udevadm trigger

          Third, if you installed PuTTY via Flatpak, the sandboxed environment may block direct hardware access. Flatpak applications require explicit permissions for device access. Grant PuTTY access to serial devices:

          flatpak override --user --device=all uk.org.greenend.chiark.sgtatham.putty

          After running the override command, restart PuTTY and try connecting again. If you installed PuTTY via APT instead of Flatpak, this step does not apply. Let me know which of these resolves the issue, or if you see specific error messages when launching PuTTY from the terminal.

          Reply

Leave a Comment