How to Install PyCharm 2024.1 in Ubuntu 22.04 & 24.04

Last updated: April 9, 2024 — Leave a comment

This simple tutorial shows how to install the latest PyCharm IDE in Ubuntu 22.04, Ubuntu 23.10, and Ubuntu 24.04.

The PyCharm Python IDE released version 2024.1 a few days ago. The new release features:

  • Documentation previews for Hugging Face models and datasets
  • local ML-based full line code completion for JavaScript and TypeScript
  • sticky lines in the editor
  • in-editor code review
  • New Terminal in Beta.
  • And new AI assistant functionality (Pro only)

The new release is available to install in Ubuntu via different ways. They include Snap, Flatpak, official tarball, and Ubuntu PPA. Choose either one that you prefer.

Method 1: Install PyCharm via Snap package

JetBrains provides official Linux package through both Snap and tarball. Which is super easy to install for Ubuntu users.

The Snap package Features:

  • Official package by JetBrains.
  • Run in sandbox environment.
  • amd64 (x86_64) only.

For all current Ubuntu releases, just launch Ubuntu Software (or App Center), then search and install pycharm-community or pycharm-professional.

Or, run command below in a terminal window (Ctrl+Alt+T) instead to install the package:

snap install pycharm-community --classic

The snap package installs updates automatically. To manually check (and install if any) updates, use command:

snap refresh pycharm-community

Method 2: Install PyCharm via Flatpak package

Another easy way to install PyCharm is using Flatpak package. Which works in most Linux, though also run in sandbox environment.

The Flatpak package Features:

  • Community maintained.
  • Run in sandbox environment.
  • amd64 (x86_64) and arm64 support.

Ubuntu users just need to press Ctrl+Alt+T on keyboard to open terminal. Then run the 2 commands below one by one to install the package.

  • First, run command to install the Flatpak daemon:
    sudo apt install flatpak

  • Then, run the command below to install PyCharm as Flatpak:
    flatpak install https://dl.flathub.org/repo/appstream/com.jetbrains.PyCharm-Community.flatpakref

    You may replace Community in command with Professional to install the professional edition.

If you’re first time installing app as Flatpak, log out and back in for the app icon visible in system app launcher.

To update the Flatpak package, use command:

flatpak update com.jetbrains.PyCharm-Community

Method 3: Install PyCharm via Official Tarball

If you don’t like or have issue for the IDE running in sandbox, then use the official Linux tarball instead!

The Linux Tarball Features:

  • Official package by JetBrains.
  • Portable, no installation required.
  • amd64 (x86_64) and arm64 support.

1. First, go to the official download page via the link below:

Depends on you needs, either download the Professional, or scroll down and select the Community edition. For ARM64, click the down arrow (▿) icon to select from drop-down menu.

2. After downloaded the tarball, just extract and move the source folder to any location that you want for long time use.

In my case, I created a “Apps” folder in user home, and put PyCharm source folder into it as sub-directory.

3. Without installation, you can now go to the ‘bin‘ sub-folder, right-click on “pycharm.sh” and select “Run as Program” to launch the IDE.

4. Create app shortcut, so to launch from start/application menu.

  • First, press Ctrl+H in file manager and navigate to .local/share/applications directory. Then, create a new document and re-name to ‘pycharm.desktop’.For choice, you may open terminal (Ctrl+Alt+T) and run command to create the file instead:
    gedit ~/.local/share/applications/pycharm.desktop

    Replace gedit with gnome-text-editor for Ubuntu 24.04 or other text editor according to your desktop environment. Or use nano that works in most desktops

  • Then, paste following lines into the file you just created and save it.
    [Desktop Entry]
    Name=PyCharm Community
    Exec=/path/to/pycharm-executable-file
    Icon=/path/to/pycharm-icon-file
    Terminal=false
    Type=Application
    Categories=Application;Development;
    Keywords=ide;python;charm;
    StartupWMClass=jetbrains-pycharm-ce

    Here, you need to replace the values of ‘Exec‘ and ‘Icon‘ according where you put the source folder. And, change ‘Name’ value for Professional edition.

If everything’s done correctly, you can then search for and launch PyCharm from app launcher or the overview screen depends on your DE a few moments later:

Method 4: Install PyCharm .deb package via Ubuntu PPA

Another choice to avoid Snap and Flatpak, is using an Ubuntu PPA. However, there are only third-party maintained PPAs.

The PPA features:

  • Third-party maintained.
  • PyCharm Community only so far.
  • amd64 (x86_64) only so far.
  • supports Ubuntu 22.04, Ubuntu 23.10 only so far.

As far as I know, the xtradeb PPA is keeping updated with the most recent packages including PyCharm Community.

To install PyCharm from the PPA, press Ctrl+Alt+T on keyboard to open terminal. And, run commands below one by one:

  • Add the PPA by running command:
    sudo add-apt-repository ppa:xtradeb/apps

  • Then install the IDE:
    sudo apt install pycharm-community

NOTE: Linux Mint user needs to run sudo apt update after adding PPA to manually refresh system package cache.

Uninstall PyCharm

For the Snap package, just remove it from Ubuntu Software or App Center, or use command:

snap remove --purge pycharm-community

For the Flatpak package, open terminal (Ctrl+Alt+T) and run command to remove it:

flatpak uninstall --delete-data com.jetbrains.PyCharm-Community

And, run flatpak uninstall --unused to remove useless run-time libraries.

For PyCharm installed via the official Tarball, just remove the source folder as well as .desktop file under .local/share/applications directory.

For the Ubuntu PPA package, open terminal and run command to remove it:

sudo apt remove --autoremove pycharm-community

Also remove the Ubuntu PPA by running command:

sudo add-apt-repository --remove ppa:xtradeb/apps

Twitter

I'm a freelance blogger who started using Ubuntu in 2007 and wishes to share my experiences and some useful tips with Ubuntu beginners and lovers. Please comment to let me know if the tutorial is outdated! And, notify me if you find any typo/grammar/language mistakes. English is not my native language. Contact me via [email protected] Buy me a coffee: https://ko-fi.com/ubuntuhandbook1

No Comments

Be the first to start the conversation.

Leave a Reply

Text formatting is available via select HTML.

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> 

*