Installing and Managing Python Packages
In the previous step, we set up a Python interpreter for our project. But sometimes our project depends on Python packages and getting those setup can be tricky.
Package Tool Window
In 2021, PyCharm added a new Packages tool window to help you see which Python packages are in your interpreter, as well as manage them. You can use this to see what packages PyCharm has installed, for example some will be installed if you select Flask as your project type such as the Jinja2 and Flask packages.

It’s important to mention that these packages belong to the current virtual environment that PyCharm also created for this project.
In this case, a virtual environment in this project directory, based on Python 3.10. You can see this information by clicking on the Status Bar.

Add PyPI Package
You can also browse and install PyPi packages such as requests; a very popular Python package. In the Packages tool window you can type in requests and PyCharm will search the PyPi repository and return the most relevant packages that match your search.
If you click the package name, the PyPi documentation for this package is shown on the right-hand side. Not all minor packages have PyPi documentation so in some cases it will not be available.
To install the package, you can click Install which will use the latest stable version of the package. You don’t need to install it using the command line. You can also select a specific version to install if you need to.

If you now check your list of installed packages, requests is there, ready to be imported and used in our scripts. You might also want to delete a package. In this case, you need to click the three dots and then select Delete package.
PyCharm can manage local or remote environments, pip vs. conda vs. pipenv vs. poetry, and more!
Add Repository Package
We’ve covered how to install packages from PyPi, but you might also want to install packages from a version control system like GitHub or from your local machine. In this case, you can click Add packages in the Package tool window and then you have two options:
- Add packages from version control
- Select the version control system that you’re using and specify a path to the target repository.
- You can provide the local path to your package directory or an archive.
In both cases, you can select the -e checkbox to install the package in editable mode.
Conclusion
You just saw how easy it is to install and manage Python packages in PyCharm. Another quick tip is that sometimes people install Python packages from the local terminal without having the virtual environment activated. In this case, when you import the package using PyCharm, you will see a red squiggly line and an error saying ‘No module named requests’, for example. You can prevent this kind of error by using PyCharm to install and upgrade your packages.
In the next step, we’ll see some basic code assistance tips that will boost your productivity in PyCharm.
Video
You can also check out the video for this step from our Getting Started series on YouTube:
HOW TO INSTALL PACKAGE IN PYTHON WITH PYCHARM IDE

A package is a collection of module files while a module is a file that contains a collection of functions, classes and other Python code.
Okay, lets check this out .
- First, create a new respository on github and clone in your Pycharm application. (you can see the tutorial in my stories before this stories)
- After opened the project sheet on pycharm. click settings > project > project interpreter. click the sign (+) in the lower right corner of the logo settings.
3. Find the packages that you want to download in the ‘search coloumn’. after that, click “Install Package”.
4. You can check whether the package is installed or not in ur PyCharm. click terminal and write “pip install the name of the package that was downloaded” example “pip install beautifulsoup4”
5. TADAAA. Package Beautifulsoup4 already to use.
Beautifulsoup4 package uses will be discussed in the next story, stay tune!!
Managing Packages in Pycharm
Pycharm supports installation, uninstallation, and up-gradation of Python packages. By default, Pycharm makes use of the pip package manager for the same. Similarly, conda package managers are used to handle Conda environments. In this article, we will look into the process of managing python packages in Pycharm.
Installing Packages:
Follow the below steps to install packages in Pycharm:
- Step 1: Create a Pycharm project. It will look like the below image.
- Step 2: Now go to File → settings → project → python interpreter. A screen will appear like below.
- Step 3: Now click on the “+” symbol on the left bottom corner. A new screen will appear like below. Search for the package you want to install (e.g. matplotlib, numpy , scipy, etc).
Depending upon your need check the boxes:
- Specify version: This is used to install a specific version of the package. For this, you will also need to specify the version you need to install. By default, it takes the latest version.
- Options: If checked, it can be used to run pip commands in the text field (e.g. pip install Flask).
- Install to user’s site packages directory <path>: If checked, you can specify where(ie, specific directory) you want the package to be installed. By default, it installs packages in the current interpreter. This option is not available for Conda environments.
- Step 4: At the end click Install Package. Based on your internet speed it will take some time.
After all these steps in the bottom corner, you will get a message like “[YOUR PACKAGE NAME] is installed successfully”.
Uninstalling Packages:
To uninstall a package in Pycharm follow the below steps:
- Step 1: Navigate to setting → Project Interpreter as shown below.

- Step 2: Select the Package you need to uninstall and click Uninstall or “-“ symbol.

This will uninstall your selected package.
Upgrading Packages:
Pycharm automatically tracks if a python package is outdated. It lists the currently installed package version (column Version), and the latest available version (column Latest version). Pycharm marks newer available versions of the packages with an arrow and suggests to upgrade them .
To upgrade an existing package in Pycharm follow the below steps:
- Step 1: Navigate to setting → Project Interpreter as shown below.
- Step 2: Select the package and click on the Upgrade symbol (⇑) to upgrade the selected package.

This will upgrade the selected package to the latest version. You will also receive an acknowledgment if the upgradation fails or is successful.
Установка модулей pip в проект PyCharm
При изучении программирования на Python в среде разработки PyCharm (PC), у меня возникли проблемы с установкой модулей из менеджера библиотек PiP, поэтому немного разобравшись в проблеме, я решил написать эту статью:
- В среде разработки PyCharm нажимаем: меню File — Settings, Project: (имя проекта), Project interpreter, справа от списка установленных модулей жмем +, в поиске вводим «Название библиотеки/модуля», выбираем найденный модуль, потом внизу жмем Install Package.
- В окне Terminal вводим: «pip install название_модуля» (без » )
- Скачиваем библиотеку/модуль с сайта pypi.org и устанавливаем через Terminal в PyCharm указав полный путь к файлу: pip install C:/user/downloads/назв_мод.whl
Вариант 3 у меня был, когда я изучал уроки «Распознавание речи» с сайта itproger.com для установки модуля PyAudio, пришлось сначала скачать его на компьютер и только потом установить его указав путь к файлу на жестком диске «pip install С:/user/PyAudio‑0.2.11‑cp37‑cp37m‑win_amd64.whl «
Пишите в комментариях, если я что-то забыл указать!
Похожие статьи:
-
06.03.2017[РЕШЕНО] WYSIWYG WB Ошибка при созданий Базы Данных(0)
10.12.2015Проблема с активацией доргена PandoraBox || Как активировать PandoraBox(31)
10.08.2021[SOFT] Лучший редактор PDF файла(0)
12.09.2016Создание дорвеев с помощью ZennoPoster на WordPress(3)
Комментарии
Ксения
08.07.2020 — 01:27:: py -3 — это эквивалент команды python3 из ubuntu :: Пример глобальной установки пакета в определённую версию py -3 -m pip install virtualenv :: Пример использования глобальной библиотеки py -3 -m virtualenv venv
iMarketing5
08.07.2020 — 13:32спасибо большое, дельный комментарий
Борис
15.07.2020 — 17:01Спасибо огромное, полчаса сидел в раздумьях почему cmd всё видит и воспроизводит (модуль ставил через pip) а pycharm не в какую не хочет. Теперь всё работает. 20 мая ’19 в 10:30
iMarketing5
15.07.2020 — 23:30Спасибо за комментарий! Если встретите, что-то интересное, пишите в комментарии, будем разбираться вместе!