Skip to content

Installation

Basic Install

pip install django-query-doctor

With Extras

django-query-doctor has optional dependencies for enhanced functionality:

pip install django-query-doctor[rich]
pip install django-query-doctor[celery]
pip install django-query-doctor[otel]
pip install django-query-doctor[all]

Requirements

Dependency Version
Python >= 3.10
Django >= 4.2 (tested up to 6.0)

No other dependencies are required for the base install.

Verify Installation

>>> import query_doctor
>>> print(query_doctor.__version__)
1.0.3

Add to Django

settings.py
INSTALLED_APPS = [
    ...,
    "query_doctor",
]

Tip

You don't need to add the middleware right away. You can start with just the management commands and add the middleware later when you want real-time analysis.

Next Steps