Set up Command Prompt for Python in Windows10

Learn Tricking
3 min readApr 26, 2024

Setting up Command Prompt for Python in Windows 10 is crucial for coding in Python. This guide will walk you through the steps to configure Command Prompt, making it easier to run Python scripts and programs on your Windows 10 system. Let’s dive in!

Python has become incredibly popular in the world of coding today. When you install Python, you also get an integrated development environment (IDE) called IDLE. This allows you to write and run your Python programs seamlessly. However, you can also run Python programs using the Command Prompt (CMD), which is the default command-line interpreter on Windows.

To use Python in the command-line, you need to set up the environment variable in Windows. Here’s how you can add Python Environment to the Windows path:

Step 1: To set up Python on CMD, first, check if Python is installed on your machine. You can do this by searching for Python in the Windows search bar. If Python appears in the search results, you’re all set.

If python is not installed on your computer, you can refer to How to install Python on Windows?

Step 2: Check if Python is already set up

To check if Python is already set up in Command Prompt, open the command prompt and type python. If you see a Python version displayed, it means Python is already set up on your system.

From the screenshot above, it appears that Python is not set up in your Command Prompt. When you type python and nothing happens, it indicates that the python command prompt is not recognized.

Step 3: Open Python IDLE

1. Open the Windows search bar and search for “idle”.

2. Right-click on the Python IDLE app.

3. Click on “Open file location” to locate the IDLE executable.

4. If you don’t see the option, right-click on the app to find it.

After following the previous steps and clicking on “Open file location,” a Windows Explorer window will open, showing the location of the Python IDLE executable file.

CLICK HERE TO CNTINUE

--

--

Learn Tricking

Learn programming languages like python, php, java, c++. You can also learn cyber security, ethical hacking, termux, kali linux web devep, seo and monitization.