redislite
Redis built into a python package
What it is and what it does
Redislite wraps Redis into a Python package that automatically installs, configures, and manages a Redis server instance on first use. Instead of running Redis as a separate service, you import Redislite and create a Redis object pointing to a local database file; the server starts automatically and shuts down cleanly when your Python process exits. It provides drop-in replacements for redis-py's Redis and StrictRedis classes, so existing code using those libraries can often switch to Redislite with minimal changes.
The package supports all standard Redis operations—keys, sets, hashes, lists, sorted sets—plus advanced features like replication and clustering. You can run a single shared server, multiple independent servers in the same script, or configure different instances with custom settings. Data persists across runs when you reuse the same database file. Security defaults to user-only access on the local system.
Use it for:
- Development and testing: use Redis features locally without Docker or a running service.
- Embedded caching: add a persistent key-value cache to a standalone Python application.
- Prototyping: quickly test Redis-based code before deploying to a production Redis cluster.
- Multi-server simulation: spin up multiple independent Redis instances in a single script for testing replication or failover logic.
- Migrating from redis-py: patch existing code that uses redis-py to run against Redislite with minimal refactoring.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Redislite embeds a self-contained Redis server into a Python package, providing Redis key-value store functionality without requiring a separate server installation or management.
Yes, if you need local Redis functionality for development, testing, or embedding in a standalone application and can tolerate dormant maintenance. The package is stable (Production/Stable classifier), has no known vulnerabilities, and works on modern Python versions. Not recommended for production services requiring active security updates or recent Redis features; use a standalone Redis server instead.
Install
redislite on PyPI
pip
pip install redisliteuv
uv add redislitepoetry
poetry add redisliteInstalling redislite
Before you install
Medium install friction due to compiled wheels for multiple Python versions (3.8–3.12, including PyPy variants). Last release was 2023-12-01, over 987 days ago; the repository is not archived but marked dormant. Requires Python development headers on Linux systems.
License in practice
BSD License (permissive) places no significant restrictions on use, modification, or distribution in commercial or private projects.
Quickstart
pip install redislite
from redislite import Redis
redis_connection = Redis('/tmp/redis.db')
redis_connection.set('key', 'value')
print(redis_connection.get('key'))
On Linux, Python development headers must be installed before installation (e.g., python-dev on Ubuntu/Debian, python-devel on Redhat/Fedora).
Verify before relying
- Current stability and bug-fix cadence given 987 days since last release and dormant maintenance status.
- Whether the embedded Redis version (6.2) meets security or feature requirements for your use case.
- Performance characteristics compared to connecting to a standalone Redis server for production workloads.
Package facts
| License | BSD License (permissive) |
| Python support | supports the current Python release (>=3.8.0) |
| Install friction | medium — platform-specific wheel |
| Runtime dependencies | 3 — redis, psutil, setuptools |
| Maintenance | dormant — 987 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 94,596/month — #13,322 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: redislite-6.2.912183-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; redislite-6.2.912183-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; redislite-6.2.912183-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; redislite-6.2.912183-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; redislite-6.2.912183-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; redislite-6.2.912183-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; redislite-6.2.912183-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; redislite-6.2.912183-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Keywords: redis, sqlite, python, service, integrated
Tags
More Libraries packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
pluggyPluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
python-dateutilProvides parsing, arithmetic, and recurrence…
permissive · top 100 on PyPI
sixSix provides utility functions to write Python…
permissive · top 100 on PyPI
pytestpytest is a testing framework that lets you…
permissive · top 100 on PyPI
flask-redisIntegrates Redis into Flask applications as a…
unclear · top 15,000 on PyPI
redisPython client library for connecting to and…
permissive · top 1,000 on PyPI
fakeredisfakeredis provides an in-memory, pure-Python…
permissive · top 1,000 on PyPI
valkeyPython client library for connecting to and…
permissive · top 5,000 on PyPI
burner-redisRuns a Redis-compatible in-process database…
permissive · top 5,000 on PyPI
redis-entraidProvides Entra ID (Azure Active Directory)…
unclear · top 5,000 on PyPI
RLTestRLTest is a test framework for Redis and Redis…
permissive · top 15,000 on PyPI
redis-cliProvides a lightweight wrapper around redis-py…
permissive · top 15,000 on PyPI
py-redisA convenience wrapper around the official Redis…
permissive · top 15,000 on PyPI
pytest-redisA pytest plugin that provides fixtures for…
copyleft · top 15,000 on PyPI