0
0
Flaskframework~15 mins

Installing Flask - Try It Yourself

Choose your learning style9 modes available
Installing Flask
📖 Scenario: You want to start building a web app using Flask, a popular Python web framework. Before writing any code, you need to install Flask properly in your project environment.
🎯 Goal: Learn how to set up a Python virtual environment and install Flask using the command line.
📋 What You'll Learn
Create a Python virtual environment named venv
Activate the venv environment
Install Flask version 2.3.2 inside the virtual environment
Verify Flask installation by checking the installed packages
💡 Why This Matters
🌍 Real World
Setting up Flask correctly is the first step to building web applications in Python. Using virtual environments keeps projects organized and avoids conflicts between package versions.
💼 Career
Many software development jobs require knowledge of environment management and package installation to maintain clean, reproducible projects.
Progress0 / 4 steps
1
Create a Python virtual environment
Open your command line terminal and create a Python virtual environment named venv by running the command python -m venv venv.
Flask
Need a hint?

Use the python -m venv command followed by the environment name venv.

2
Activate the virtual environment
Activate the venv virtual environment using the appropriate command for your operating system: source venv/bin/activate for macOS/Linux or venv\Scripts\activate for Windows.
Flask
Need a hint?

On Windows, use venv\Scripts\activate. On macOS/Linux, use source venv/bin/activate.

3
Install Flask version 2.3.2
With the virtual environment activated, install Flask version 2.3.2 by running the command pip install Flask==2.3.2.
Flask
Need a hint?

Use pip install Flask==2.3.2 to install the exact Flask version.

4
Verify Flask installation
Check that Flask version 2.3.2 is installed by running pip show Flask and verifying the version number in the output.
Flask
Need a hint?

Use pip show Flask to see the installed Flask version and details.