Install Django on Fedora 35/34/33/32/31/30

In this guide, we will take you through the steps to Install Django on Fedora 35/34/33/32/31/30. Django is a free and open source high-level Python Web framework built by experienced developers to encourage rapid development and pragmatic design. Django takes care of much of the hassle of Web development, so you can focus on writing your app without needing to reinvent the wheel.

There are two methods that you can use to install Django on Fedora 35/34/33/32/31/30.

  1. Install Django on Fedora with pip|pip3
  2. Install Django on Fedora by building from Git

Let’s look at how to use either of the methods to Install Django on Fedora 31/30/29.

Your Fedora system should come with Python 3, if it doesn’t have it, install by running the commands below on your terminal.

sudo dnf -y install vim python3 python3-pip

The easiest and quickest method of installing Django on Fedora 31/30/29 is with pip3.

Check your Python version

$ python3 -V

Python 3.7.0

$ python3 -V

Python 3.10.0

Ensure pip3 is installed

$ sudo dnf -y install python3-pip

$ pip3 -V

pip 21.2.3 from /usr/lib/python3.10/site-packages/pip (python 3.10)

Once installed, Download and install Django on Fedora 31/30/29 with it.

pip3 install --user Django

Installation output:

Collecting Django

Downloading Django-3.2.9-py3-none-any.whl (7.9 MB)

|████████████████████████████████| 7.9 MB 9.8 MB/s

Collecting sqlparse>=0.2.2

Downloading sqlparse-0.4.2-py3-none-any.whl (42 kB)

|████████████████████████████████| 42 kB 2.4 MB/s

Requirement already satisfied: pytz in /usr/lib/python3.10/site-packages (from Django) (2021.1)

Collecting asgiref<4,>=3.3.2

Downloading asgiref-3.4.1-py3-none-any.whl (25 kB)

Installing collected packages: sqlparse, asgiref, Django

Successfully installed Django-3.2.9 asgiref-3.4.1 sqlparse-0.4.2

The installation of Django will give you django-admin command to manage Projects,

$ which django-admin


Check django-admin version using:

$ django-admin --version


You can also install Django from source code. Make sure you have Git installed:

sudo dnf -y install git

Check out Django’s main development branch like so:

git clone

This will create a directory django in your current directory. Next is to make Django’s code importable and django-admin utility command available:

pip3 install -e django/

Create a Django test application by running

mkdir projects

cd projects

django-admin startproject test_app

cd test_app

test_app is the name of our Django Project.

Apply pending migrations

$ python3 migrate

Operations to perform:

Apply all migrations: admin, auth, contenttypes, sessions

Running migrations:

Applying contenttypes.0001_initial... OK

Applying auth.0001_initial... OK

Applying admin.0001_initial... OK

Applying admin.0002_logentry_remove_auto_add... OK

Applying admin.0003_logentry_add_action_flag_choices... OK

Applying contenttypes.0002_remove_content_type_name... OK

Applying auth.0002_alter_permission_name_max_length... OK

Applying auth.0003_alter_user_email_max_length... OK

Applying auth.0004_alter_user_username_opts... OK

Applying auth.0005_alter_user_last_login_null... OK

Applying auth.0006_require_contenttypes_0002... OK

Applying auth.0007_alter_validators_add_error_messages... OK

Applying auth.0008_alter_user_username_max_length... OK

Applying auth.0009_alter_user_last_name_max_length... OK

Applying sessions.0001_initial... OK

Create a Django project superuser account by running the following commands from your Django application directory.

$ python3 createsuperuser

Username (leave blank to use 'jmutai'): admin

Email address:


Password (again):

Superuser created successfully.

Input your admin username, email address, and password.

Note that by default Django doesn’t allow external access to the application, you need to explicitly define an ACL.

vim test_app/

Edit the lineALLOWED_HOSTS to whitelist your Computer IP or LAN subnet.


You can now start Django application server:

$ python3 runserver

Watching for file changes with StatReloader

Performing system checks...

System check identified no issues (0 silenced).

November 04, 2021 - 21:40:16

Django version 3.2.9, using settings 'test_app.settings'

Starting development server at

Quit the server with CONTROL-C.

If you open the URL http://[server IP/hostname]:8090 you should see a successful message like below:


Django Administration page is available on :8090/admin


Login with created username and password:


The admin page allows you to add other users, add groups, change password e.t.c. It looks like below:


Enjoy writing your Web application with Django Framework on Fedora 35/34/33/32/31/30. Don’t forget to check other Fedora articles available on our website.



ComputingPost — Linux Howtos, Tutorials, Guides, News, Tips and Tricks.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store

ComputingPost — Linux Howtos, Tutorials, Guides, News, Tips and Tricks.