Setup A Django Application

Setup A Django Application


1 min read

Play this article

Step 1 - Install Python

You need to have Python before installing Django


Go to and download the executable run through installation


In linux chances are that you already get python installed but if not install for your distribution


sudo apt-get install python3


sudo pacman -S python


sudo dnf install python3


sudo emerge -a python

Mac OS

In mac os you already get python pre installed

Step 2 - Setup Virtual Environment

We can create a virtual env so we can keep packages seperate for our project

Install Virtual Env

pip install virtualenv

Create a VirtualEnv

virtualenv venv

Activate VirtualEnv

source venv/bin/activate

Step 3 - Install Django

To Install Django Run The Following Command:

pip install django

Step 4 - Create New Django Project

To create a new django project run the following command:

django-admin startproject my-project

Step 5 - Create Admin User

To create a admin user run the following command

python createsuperuser

Run The App !

python runserver