You should open the terminal inside the VSCode and install the modules you want. something like👇

if that's not you meant, please let me know.

Answer from Mithilesh on Stack Overflow
🌐
Reddit
https://reddit.com › r/learnpython › how to install packages on vs code
r/learnpython on Reddit: How to install packages on VS Code
July 6, 2025 -

Hello! I'm completely brand new to any type of programming and am taking a coding class now to get introduced to it.

As part of my final project I need to make a program with astropy and numpy, but I have no idea how to install it in VS Code, which is what I've been using all semester. Whenever typing the normal install codes others have described in other posts, it gives me a syntax error. I have Python 3.13.3 installed, and that's the version it said it uses.

This whole thing is very confusing for me, so I hope it's not some small stupid mistake I'm making, but any help would be greatly appreciated

Discussions

How to install a new python module on VSCode? - Stack Overflow
Explore Stack Internal ... Save this question. Show activity on this post. I'm trying to install new python modules on my computer and I know how to install through the terminal, but I wish to know if there is a way to install a new module directly through VSCode (like it is possible on PyCharm)? More on stackoverflow.com
🌐 stackoverflow.com
May 13, 2021
How to install module of python in VS code - Stack Overflow
Please share process how to install external modules i cann't access modules ss of my vs code screen More on stackoverflow.com
🌐 stackoverflow.com
How do i install Python modules through Visual studio???

Open terminal, pip install

More on reddit.com
🌐 r/vscode
4
0
December 18, 2019
How to install Python packages for a VS Code virtual environment? - Stack Overflow
When I follow the command in the VS Code Python tutorial to install a package in the virtual environment, the script only runs successfully using the global interpreter, not the newly created virtual More on stackoverflow.com
🌐 stackoverflow.com
🌐
Visual Studio Code
https://code.visualstudio.com › docs › python › python-tutorial
Getting Started with Python in VS Code
November 3, 2021 - You can use the New folder button to quickly create a folder. Now that you have a code file in your Workspace, enter the following source code in hello.py: ... When you start typing print, notice how IntelliSense presents auto-completion options. IntelliSense and auto-completions work for standard Python modules as well as other packages you've installed into the environment of the selected Python interpreter.
🌐
pythontutorials
https://pythontutorials.net › blog › how-to-install-a-new-python-module-on-vscode
How to Install Python Modules Directly in VSCode Without Using the Terminal: A Step-by-Step Guide — pythontutorials.net
This guide will walk you through two intuitive GUI methods to install modules directly in VSCode, along with verification steps, troubleshooting tips, and why these methods might be preferable for your workflow. ... VSCode Installed: Download from the official VSCode website. Python Installed: Download from python.org (check "Add Python to PATH" during installation).
🌐
Code2care
https://code2care.org › home › python › how to install python modules in vs code
How to Install Python Modules in VS Code | Code2care
January 26, 2026 - Open Pallete (Command + Shift + P for Mac, or Control + Shift + P for Windows) and type Python: Select Interpreter and select your Python Version. Now you can run the pip command to install your required modules.
🌐
Hashnode
https://emminex.hashnode.dev › the tech-thusiast hub › #python › how to install python libraries in visual studio code
How to install Python Libraries in Visual Studio Code
May 29, 2024 - Run the installer and follow the setup wizard to install VS Code. Launch VS Code. Click on the Extensions icon in the Activity Bar on the left (it looks like four squares) or press Ctrl+Shift+X (or CMD+Shift+X on macOS).
Find elsewhere
🌐
CodeGenes
https://codegenes.net › blog › how-to-install-python-packages-in-visual-studio-code
How to Install Python Packages in Visual Studio Code — codegenes.net
By keeping your dependencies organized inside virtual environments, using python -m pip install inside the integrated terminal, and verifying that VS Code is connected to the right interpreter via Python: Select Interpreter, you can prevent ...
🌐
Microsoft Learn
https://learn.microsoft.com › en-us › visualstudio › python › tutorial-working-with-python-in-visual-studio-step-05-installing-packages
Tutorial Step 5: Install Packages in Python Environment | Microsoft Learn
To resolve the matplotlib import ... global environment: In the Python Environments window, select the default environment for new Python projects, then select Packages (PyPI) in the dropdown menu....
🌐
Medium
https://medium.com › @gbemiadekoya › importing-python-libraries-in-vs-code-e9e7806586a7
Importing Python Libraries in VS Code | by Gbemisola Adekoya | Medium
November 24, 2023 - To import your library, create a new terminal by going to the command palette(ctrl+shift+p) and type ‘Python:create terminal’. ... In your new terminal, type e.g “pip install pandas” or whatever library you want to install and press enter.
🌐
CodeRivers
https://coderivers.org › blog › how-to-install-python-packages-in-visual-studio-code
Installing Python Packages in Visual Studio Code — CodeRivers
For pip, run the following command in the terminal: ... A virtual environment is a self-contained Python environment that allows you to isolate your project's dependencies. Open the integrated terminal in VS Code. Navigate to your project directory. Create a virtual environment using venv (a ...
🌐
Stack Overflow
https://stackoverflow.com › questions › 74645554 › how-to-install-module-of-python-in-vs-code
How to install module of python in VS code - Stack Overflow
Please share process how to install external modules ... I guess you're on PowerShell. Just type the command python to go into the Python CLI.
🌐
DEV Community
https://dev.to › emminex › how-to-install-python-libraries-in-visual-studio-code-38i1
How to install Python Libraries in Visual Studio Code - DEV Community
May 30, 2024 - Head over to the official Python website and download the latest version. Run the installer and follow the on-screen instructions. It’s crucial to check the “Add Python to PATH” box during installation.
🌐
Reddit
https://reddit.com › r/vscode › how do i install python modules through visual studio???
r/vscode on Reddit: How do i install Python modules through Visual studio???
December 18, 2019 - It probably would've been quicker ... calls your system's via terminal commands. Install nodules like you would otherwise, pip install...
🌐
Brainly
https://brainly.com › computers and technology › high school › how do you install python modules in visual studio code?
[FREE] How do you install Python modules in Visual Studio Code? - brainly.com
November 27, 2023 - Open the terminal, type the pip install command, wait for the installation to complete, and then import the module in your code. To install Python modules in Visual Studio Code, you can use the integrated terminal and the Python Package Manager ...
🌐
Reddit
https://reddit.com › r/learnpython › how to import library in vs code
r/learnpython on Reddit: How to import library in VS CODE
November 5, 2021 - Once you've created the venv using pipenv install <command> you can use the virtual environment (venv) in VS Code by pressing ctrl+shift+p and typing python interpreter (you can also change this on the bottom left window by clicking where it says python), click the reload button (VS Code takes awhile to see newly created venvs) in the drop down window and start typing the name of the venv that pipenv made (the name in brackets) select that and away you should go.
🌐
Medium
https://medium.com › @faisalkhalidhassan › python-packages-installation-in-vscode-59eab8e2a866
Python Packages Installation in VScode | by Faisal Khalid Hassan | Medium
November 23, 2024 - pip is the package installer for python, it is a tool to install python packages from the python package index (pypi). To install type on the terminal of the vscode: pip install “package name”
🌐
Glarity
https://askai.glarity.app › search › How-can-I-install-modules-in-Visual-Studio-Code--VS-Code
How can I install modules in Visual Studio Code (VS Code)? - Ask and Answer - Glarity
3. Another method is to create a virtual environment using "python -m venv" and install modules in that environment. 4. Utilize the command palette (Ctrl+Shift+P) to select the Python interpreter and manage modules.