Django - Environment: Step 1 Installing Python
Django - Environment: Step 1 Installing Python
htm
Chapters Categories
Django - Environment
If you're on one of the latest Linux or Mac OS X distribution, you probably already
have Python installed. You can verify it by typing python command at a command
prompt. If you see something like this, then Python is installed.
$ python
Python 2.7.5 (default, Jun 17 2014, 18:11:42)
[GCC 4.8.2 20140120 (Red Hat 4.8.2-16)] on linux2
Otherwise, you can download and install the latest version of Python from the link
http://www.python.org/download.
You can download the latest version of Django from the link http://
www.djangoproject.com/download.
1 of 6 09-06-2025, 22:34
Django Environment Setup https://www.tutorialspoint.com/django/django_environment.htm
You have two ways of installing Django if you are running Linux or Mac OS system −
You can use the package manager of your OS, or use easy_install or pip if
installed.
We will cover the second option as the first one depends on your OS distribution. If
you have decided to follow the first option, just be careful about the version of Django
you are installing.
Let's say you got your archive from the link above, it should be something like
Django-x.xx.tar.gz:
$ django-admin.py --version
If you see the current version of Django printed on the screen, then everything is set.
Note − For some version of Django it will be django-admin the ".py" is removed.
We assume you have your Django archive and python installed on your computer.
On some version of windows (windows 7) you might need to make sure the Path
system variable has the path the following C:\Python34\;C:\Python34\Lib\site-
packages\django\bin\ in it, of course depending on your Python version.
c:\>cd c:\Django-x.xx
Next, install Django by running the following command for which you will need
2 of 6 09-06-2025, 22:34
Django Environment Setup https://www.tutorialspoint.com/django/django_environment.htm
To test your installation, open a command prompt and type the following command −
If you see the current version of Django printed on screen, then everything is set.
OR
c:\> python
>>> import django
>>> django.VERSION
MySQL (http://www.mysql.com/)
PostgreSQL (http://www.postgresql.org/)
SQLite 3 (http://www.sqlite.org/)
Oracle (http://www.oracle.com/)
MongoDb (https://django-mongodb-engine.readthedocs.org)
3 of 6 09-06-2025, 22:34
Django Environment Setup https://www.tutorialspoint.com/django/django_environment.htm
However, Django does support Apache and other popular web servers such as
Lighttpd. We will discuss both the approaches in coming chapters while working with
different examples.
TOP TUTORIALS
Python Tutorial
Java Tutorial
C++ Tutorial
C Programming Tutorial
C# Tutorial
PHP Tutorial
R Tutorial
HTML Tutorial
CSS Tutorial
JavaScript Tutorial
SQL Tutorial
TRENDING TECHNOLOGIES
Git Tutorial
Docker Tutorial
Kubernetes Tutorial
DSA Tutorial
SDLC Tutorial
Unix Tutorial
4 of 6 09-06-2025, 22:34