How to Install Eclipse IDE on Ubuntu 20.04

install eclipse on ubuntu 20.04 lts

Eclipse is one of the most popular open-source IDE (Integrated Development Environment) for software developers. It is popular for Java-based applications, also used for C/C++, PHP, and Perl and other web projects.

Eclipse is a really powerful IDE that supports many programming languages. It provides numerous plugins and extensions for enhancing the functionality of your Eclipse such as source code version control (git, svn), class diagram generator, GUI builder.

This tutorial will show you 2 methods to install Eclipse on Ubuntu 20.04 LTS machine.


In order to install Eclipse IDE, you have to install JRE (Java Runtime Environment) on your Ubuntu machine:

$ sudo apt update
$ sudo apt install default-jre

To verify that Java was successfully installed, let's run:

$ java --version


openjdk 11.0.11 2021-04-20
OpenJDK Runtime Environment (build 11.0.11+9-Ubuntu-0ubuntu2.20.04)
OpenJDK 64-Bit Server VM (build 11.0.11+9-Ubuntu-0ubuntu2.20.04, mixed mode, sharing)

Install Eclipse by installer package [Method 1]

At the time of this writing, the latest version of Eclipse is: Eclipse IDE 2020-06. Eclipse can be downloaded via the browser on its official website

By default, the installer package is downloaded into the directory '~/Downloads' with name: 'eclipse-inst-linux64.tar.gz'.

Or by using the wget command as:

$ wget

Let's extract the downloaded tarball file to the directory '/opt' by running the following command:

$ sudo tar -xf eclipse-inst-linux64.tar.gz -C /opt
Eclipse installer: eclipse-inst

In order to install Eclipse, launch the installer file 'eclipse-inst' by running the following command:

$ cd /opt/eclipse-installer
$ ./eclipse-inst

Eclipse packages window appears, let's choose your favorite package IDE.

Eclipse installer window

For example, select the Eclipse IDE for C/C++ Developers then click INSTALL

Eclipse IDE for C/C++ Developers

Next, you have to accept the Eclipse Foundation Software User Agreement.

Eclipse Software User Agreement

Now, your Eclipse IDE will be installing.

Installing Eclipse

After the installation has been completed, Eclipse is ready to be launched.

Eclipse installation by snap [ Method 2]

Installing Eclipse by snap package manager is the handiest installation method to bring the Eclipse integrated development environment to your Ubuntu machine.

$ sudo snap install --classic eclipse

In order to install an old version of Eclipse, you can use the apt package manager:

$ sudo apt install eclipse

Another simple way to install Eclipse IDE is using Ubuntu Software Center. Let's open the software center and search for Eclipse then click the Install button.

Create launcher icon

Once the Eclipse is downloaded and installed successfully, you may need to create a shortcut to launch your IDE. Using your favorite editor to create a file named 'eclipse.desktop' and enter the following lines to it:

[Desktop Entry]
Comment=Integrated Development Environment

Please note that the paths in lines 'Exec=' and 'Icon=' are depended on your system. You can find the path in Exec line by running command:

$ which eclipse

Now, let's enable the launcher icon:

$ sudo chmod +x eclipse.desktop
$ sudo mv eclipse.desktop /usr/share/applications/eclipse.desktop

That's all. From now on, you can search for eclipse and launch it in the Applications center on your Ubuntu machine.


In this tutorial, we learned how to install the Eclipse IDE on Ubuntu 20.04. You can now begin to write your own codes to create many awesome applications with Eclipse.

Thanks for reading and please leave your suggestion in the below comment section.

6 Comments... add one

  1. Installed in /root/eclipse/parallel-2020-06/eclipse/eclipse
    eclipse.desktop installed in /usr/share/applications/eclipse.desktop
    But Eclipse is not found by the system (Ubuntu 20.04).
    Great very clear instructions. I must be close.
    Thanks for any help

  2. Hello, some suggestions.
    * You can also add locale to comment field, which is more useful then the name.
    * From the installation directory, run ./eclipse -initialize to make it start faster.
    * Check the desktop file with `desktop-file-verify eclipse.desktop' before installation. It is easy to be some errors if not.
    * One could also install with `desktop-file-install eclipse.desktop' if one doesn't want to look up where they should be stored.
    * I usually add a short script in /usr/local/bin that launches the right version from /opt/Eclipse/eclipse-*/eclipse. So I rename the /opt/Eclipse/eclipse to the version number so I do remember which I have installed. I usually also make a symbolic link `ln -s eclipse eclipse-2020-12' so I also reach it as the current one. Then it is easy to have old and new installed at the same time.

    The script in /usr/local/bin/eclipse-base looks like this.
    # Make a link to this script, and it will try
    # to start an eclipse in the same directory
    # If it doesn't exists, it just will fail.

    exec /opt/Eclipse/`basename $0`/eclipse $*

    Then I only make a soft or hard link from the version number to this base, like this:
    $ ls -l eclipse*
    lrwxrwxrwx 1 root root 12 sep 23 13:39 eclipse -> eclipse-base
    lrwxrwxrwx 1 root root 12 sep 23 12:43 eclipse-2019-09 -> eclipse-base
    lrwxrwxrwx 1 root root 12 sep 23 12:42 eclipse-2019-12 -> eclipse-base
    lrwxrwxrwx 1 root root 12 sep 23 12:44 eclipse-2020-09 -> eclipse-base
    -rwxrwxr-x 1 root root 191 sep 23 12:41 eclipse-base

    Now I can easily start eclipse from command line, and based on the name, it choose right binary in /opt/Eclipes/*/eclipse to run.


Leave a Comment