How to create a Django environment and run your Django project

An aspiring software developer who is willing to learn and share her experience and journey with other people
In order to create an environment for your django project, you will have to go through some steps.
Step1:
The first step is to go to the command prompt , you can search for that on the search bar.
Step2:
In the command prompt, check if you have python installed on your local machine. if not make sure you install the latest version of python.
[https://www.python.org/downloads/]
python --version
Step3
Navigate to the directory/Folder you want to create your Django Project. I am creating my Fjango project in the desktop and in a folder called first_project, you can choose to name your folder anything just make it clear and descriptive.
cd desktop
mkdir first_project
Step4
Navigate into the folder you created
cd first_project

Step5 Create your virtual environment. (it might take long depending on your internet connection)
python -m venv env

Step 6 Activate your virtual environment
env\Scripts\activate

Step 7 Install the latest version of Django an create a Django project. Your Django project can be any name.
pip install django
django-admin startproject my_project

Note: You can also create an app for the Django project. Again you can choose to name your app anything. Just make it clear and descriptive.
python manage.py startapp

Step 8 Finally you run your server
python manage.py runserver

Step 9
Copy the port number and paste in your chrome browser

Congratulations you have successfully installed your Django project


