Update: The configuration process described in this post can be achieved
with only one management command if you install the
Windows is probably not the best production environment for
Django but sometimes one doesn’t have the
choice. In that case, a few options aleardy exist, most notably the one
developed by helicontech that relies on
Microsoft’s Web Platform Installer.
This solution, which is described here,
relies on the installation of a specific native Handler developed by
This handler manages the communication between IIS and the Django application
through the FastCGI protocol with the help of a
little python script that bridges FastCGI to WSGI. This script is derived from
the Allan Saddi flup package that is already used
by Django in the
manage.py runfcgi command. The flup package doesn’t work
under Windows and Helicontech has made the necessary adaptations to make it
work with its handler.
Since its version 7, IIS does however support FastCGI natively, so the use of a
specific handler to support Django is not needed. This post describes how to
configure and run a Django application with the native FastCGI IIS handler. For
that, I have myself adapted the Helicontech FastCGI to WSGI script to make it a
Django management command.