TeamViewer is a popular software used for remote access over the internet to and from your system for Linux, MacOS, and Windows. This application can connect to any personal computer or server in a manner that you can use it as if you were sitting in front of it. TeamViewer works as a remote control to your partner’s computer system, letting you build a remote session. Both you and your partner need to have this small application installed and started, even as non-administrators. All you need to know is your partner’s ID and password in order to control their computer.

In this article, we will explain how you can install the TeamViewer application on your Ubuntu system, both through the UI and the command line.

The commands and procedures mentioned in this article have been run on an Ubuntu 18.04 LTS system.

Installation of TeamViewer Through Ubuntu Command Line

If you prefer the command line over the graphical interface, follow these steps in order to install TeamViewer through the Ubuntu Terminal application:

Step 1: Download and add TeamViewer repository key

Open the Terminal either through the system Dash or the Ctrl+Alt+T shortcut.

First, you need to download the TeamViewer repository key as we will installing TeamViewer through its official website. Run the following command in order to download the key:

$ cd /tmp
$ wget https://download.teamviewer.com/download/linux/signature/TeamViewer2017.asc

Download TeamViewer repository key

The .asc key file will be downloaded to your Downloads folder by default.

Please add this key to your system through the following apt-key command as sudo:

$ sudo apt-key add TeamViewer2017.asc

Step 2: Add the TeamViewer repository

Run the following command to add the official TeamViewer repository from where we will be installing TeamViewer.

For TeamViewer Stable version:

$ sudo sh -c 'echo "deb http://linux.teamviewer.com/deb stable main" >> /etc/apt/sources.list.d/teamviewer.list'

For TeamViewer Preview version:

$ sudo sh -c 'echo "deb http://linux.teamviewer.com/deb preview main" >> /etc/apt/sources.list.d/teamviewer.list'

We are adding the repository for TeamViewer Preview version in this tutorial.

Add Teamviewer repository

Now, enter the following command as root in order to update your system’s repository index with that on the internet:

$ sudo apt update

Update Ubuntu package list

Step 3: Install TeamViewer through the apt command

Finally, run the following command as sudo in order to install TeamViewer to your system:

$ sudo apt install teamviewer

Install TeamViewer with apt

The system will prompt you with a Y/n option in order to continue the installation procedure. Please enter Y and hit Enter to continue. TeamViewer will then be installed on your system.

Step 4: Launch TeamViewer

If you wish to launch TeamViewer through the command line, enter the following command in your Terminal:

$ teamviewer

Uninstall TeamViewer

In order to uninstall TeamViewer from your system without removing any configurations you might have made, enter the following command as sudo:

$ sudo apt remove teamviewer

Uninstall TeamViewer on the shell

The system will prompt you with a Y/n option in order to begin the uninstall procedure. Please enter Y and hit Enter to begin. TeamViewer will then be removed from your system.

If you have made any configurations, you can remove TeamViewer and all those by using the following command:

$ sudo apt purge teamviewer

TeamViewer Installation on Ubuntu Through Graphical Installer

For a person who does not want to open the Command Line much, installing a software present in the Ubuntu repository through the UI is very simple. For Teamviewer, we will be downloading the .deb package and then install it through the Ubuntu Software Install.

You can download the official .deb installation package from the following website:

https://www.teamviewer.com/en/download/linux/

Scroll down on the page and click on the download link for Ubuntu, Debian (stable version) or TeamViewer Preview version.

Download TeamViewer

Save the file on your system, which will be saved to the Downloads folder by default.

Open the Downloads folder where you will be able to see the TeamViewer .deb package.

Open package with Software Installer

Right click on the package and select the Open with Software Install option from the menu. This will open the following installer:

Install TeamViewer

Click the Install button on the above window. The following authentication dialog will display for you to provide the authentication details for a sudo user as only an authorized user can install a software on Ubuntu.

get admin privileges

Enter your password and click the Authenticate button. After that, the installation process will begin, displaying a progress bar as follows.

Installing the software

TeamViewer will then be installed to your system and you will get the following message after a successful installation:

Installation finished

Launch TeamViewer

You can launch TeamViewer any time you want by entering ‘TeamViewer’ in the Ubuntu Dash or access it from the Applications list.

Launch TeamViewer

TeamViewer started on Ubuntu

TeamViewer will open in the following view; through which you can connect or be connected to a remote computer.

Uninstall

Uninstalling Teamviewer through the UI is fairly simple. On your Ubuntu desktop Activities toolbar, click the Ubuntu Software icon.

Ubuntu Software Center

The Ubuntu Software manager will open in the following view:

Ubuntu Software center

Click on the Installed tab and locate the TeamViewer entry from the list of installed software.

Select TeamViewer in installed software list

Click the Remove icon against the TeamViewer entry.

Click on the remove button

A dialog will ask you if you are sure about removing the software from your system. Please enter the Remove button to uninstall TeamViewer. An authentication dialog will display for you to provide the authentication details for a sudo user as only an authorized user can install a software on Ubuntu. Enter your password and click the Authenticate button. After that, the uninstall process will begin, removing TeamViewer from your system.

By following the steps described in this article, you can learn to download and install the latest version of TeamViewer on your Ubuntu system, both through the graphical user interface and the command line.

How to Install TeamViewer on Ubuntu 18.04 LTS