Django Using django-redis-cache


Example

One potential implementation of Redis as a backend caching utility is the django-redis-cache package.

This example assumes you already have a Redis server operating.

$ pip install django-redis-cache

Edit your settings.py to include a CACHES object (see Django documentation on caching).

CACHES = {
    'default': {
        'BACKEND': 'redis_cache.RedisCache',
        'LOCATION': 'localhost:6379',
        'OPTIONS': {
            'DB': 0,
        }
    }
}