In this tutorial, I will reveal to you how to run Django on Android. So, stick with the tutorial to the end as well as comply with the steps carefully.
Are you discovering Django? But, you do not have a PC or laptop computer. You can still run Django on an Android phone.
How to Run Django on Android?
To run Django on Android, adhere to these actions:
- Set Up Termux from Google Play Store.
- Launch Termux on Android phone.
- Configuration Termux storage space with termux-setup-storage command.
- Allow storage space permission for Termux.
- Set up python with pkg install python command
- Make a directory for Django project– mkdir djangowebsite
- Change directory site to django internet site– cd djangowebsite
- Create another folder named django site (or whatever you desire).
- Mount virtual env to create a virtual environment– pip install virtualenv.
- Create an online setting– virtualenv venv.
- Turn on the online atmosphere–. venv/bin/activate
- Set up django– pip mount django.
- Produce a django job using Django-admin utility– django-admin startproject djangosite.
- Move the apps– python manage.py migrate.
- Run the django project on Android– python manage.py runserver.
Now, you successfully run Django on Android. You can read our Termux command lists for a far better understanding of the commands we utilized here.