In short.
Redis MCP Server is an open-source Python server that lets MCP-compatible AI assistants read and write a Redis database through 53 tools. It is aimed at developers who already run Redis. The main catch is that the assistant gets broad write and delete power unless you restrict the Redis user yourself. The package is redis-mcp-server 0.5.1, MIT licensed, with Beta status. It is built on the FastMCP framework from the mcp Python SDK and the redis-py client, and it communicates over stdio only. Its tools cover strings, hashes, lists, sets, sorted sets, streams, JSON documents, pub/sub subscriptions, vector indexes and search, server information and a Redis documentation search. The repository includes unit tests for many tools that use mocked Redis connections, an integration test that checks server startup and the tool list, a CI setup covering several operating systems, and a release workflow set up to publish to PyPI and the MCP registry. The source shows a few configuration details that need care. The command that uvx launches appears to replace some environment variables with command line defaults. The REDIS_SSL and REDIS_CLUSTER_MODE environment variables turn those settings on only for the strings true, 1 or t, so a value such as True is read as false. The vector tools expect the caller to supply embeddings. There is no built-in read-only mode. Runtime behaviour and test outcomes have not been verified.
Researched and written by an AI model and checked by a second AI model. How it works
The analysis covers the complete selected scope at [https://github.com/redis/mcp-redis], revision d66c5ea0172e0991a98c0f13c0f880246c93b2a5. That is all 60 captured files: source, tests, CI and release workflows, container and registry manifests, the Gemini extension files, the example agent, uv.lock and the MIT LICENSE notice. Linked pages and other folders or repositories are excluded. Those include the PyPI listing, the Docker Hub image, the Redis documentation search endpoint, Redis server documentation, and any issues, pull requests or release notes. Behaviour statements come from the source, tests and documentation. The runtime behaviour of the code, container and workflows has not been verified, and neither have the outcomes of the tests and CI checks.
The overview
What this resource is
Redis MCP Server is a Model Context Protocol (MCP) server published by Redis. The repository is at [https://github.com/redis/mcp-redis] and the revision described here is d66c5ea0172e0991a98c0f13c0f880246c93b2a5. The Python package is named redis-mcp-server. pyproject.toml, src/version.py and uv.lock all give version 0.5.1, and the console command redis-mcp-server maps to src.main:cli. The package metadata lists Redis as author, MIT as licence, and Development Status 4 - Beta.
An MCP server is a small program that an AI client starts and talks to, so the model can call named tools. Supported clients include Claude Desktop, VS Code with GitHub Copilot, Augment, the OpenAI Agents SDK and Gemini CLI. Here the tools wrap Redis commands. The README calls it a natural language interface for agentic applications to manage and search data in Redis. Its example prompts include storing a conversation in a stream, caching an item, and indexing and searching a vector.
The selected scope is the whole repository at that revision. That covers the source under src/, the tests, the CI and release workflows and the Dockerfile. It also covers the Gemini CLI extension files (gemini-extension.json and GEMINI.md), server.json for the MCP registry, an example OpenAI Agents SDK assistant and the MIT LICENSE file.
Overall assessment
On the evidence, this is a substantial, reasonably well-built integration rather than a stub. It registers 53 tools, and the repository's integration test checks that exact count and lists the names. It has unit tests for many tools using mocked Redis connections and one shared connection manager. Its pub/sub subscription registry is capped, and its blocking reads validate input and cap the timeout values they accept. It also supports Azure Entra ID and has a release workflow set up to publish to PyPI and the MCP registry. It is a good fit for letting an AI assistant explore, prototype against or operate a development or staging Redis database.
The main reservations are about safety and configuration rather than quality. The server has no read-only switch. Every connected assistant can delete keys, rename keys, drop consumer groups and overwrite data, up to whatever permissions the Redis user has. Some configuration behaviour in the code does not match the README (see How it works and Limitations and risks). All behaviour statements here come from the source and tests. How the server behaves against a real Redis instance has not been verified.
Who it is for
It suits developers who already run a Redis database and use an MCP-capable AI client. That includes people building agents that need session storage, caching, queues, event streams or vector similarity search. It also includes people who want an assistant to inspect keys, index information and server statistics while debugging. Teams on Azure Managed Redis can have Entra ID token authentication handled for them.
It is less suited to people without a Redis server. It also does not fit anyone who needs a hosted remote MCP endpoint: only stdio is supported, and the README says streamable HTTP support is planned for the future. It should not be pointed at a production database unless access is restricted with a Redis ACL user. The README shows how to create a read-only ACL user for that purpose.
What it can do
The tools in src/tools are grouped by Redis data type. Strings: set (optional expiry, with dict values stored as JSON text) and get. Hashes: hset, hget, hdel, hgetall and hexists, plus set_vector_in_hash and get_vector_from_hash for float32 vector fields. Lists: lpush and rpush (single or multiple values, optional expiry), lpop, rpop, lrange, llen and lrem. Sets: sadd, srem and smembers. Sorted sets: zadd, zrange and zrem. Streams: xadd, xrange, xdel, xgroup_create, xgroup_destroy, xreadgroup and xack, so consumer-group workflows are possible. JSON: json_set, json_get and json_del, with path access.
Pub/sub keeps state between calls. publish sends a message. subscribe and psubscribe return a subscription handle, read_messages polls that handle, and unsubscribe closes it. Search and vector tools: get_indexes, get_index_info and get_indexed_keys_number list and inspect indexes. create_vector_index_hash creates an HNSW index of FLOAT32 vectors, with cosine distance and 1536 dimensions by default. vector_search_hash runs a KNN (nearest-neighbour) search, and hybrid_search combines a filter expression with KNN. Key and server tools: delete, type (which also returns the TTL), expire, rename, scan_keys, scan_all_keys, dbsize, info and client_list.
One more tool, search_redis_documents, sends a natural-language question to a Redis documentation search HTTP API and returns the JSON result, with a 10 second timeout. The default endpoint is [https://redis.io/convai/api/docs/search], set in src/common/config.py, and MCP_DOCS_SEARCH_URL can change it.
Using it
What you need
You need a reachable Redis server and an MCP client that can launch a stdio server. pyproject.toml requires Python 3.10 or newer. The CI workflow is set up to test Python 3.10 to 3.14 on Ubuntu, Windows and macOS, but whether those runs pass is not known from the evidence. The Dockerfile uses python:3.14-slim. The README badge says Python 3.14+, which disagrees with the package metadata. The README's recommended launch path uses uvx, so you need the uv tool installed. npx is only needed for the optional MCP Inspector debugging tool.
The JSON tools and the search/vector tools need a Redis build or modules that provide those commands. The tool descriptions refer to Redis 8 vector search, and the tests simulate errors such as JSON module not loaded and Search module not loaded. The evidence does not say which Redis versions or editions work. The string, hash, list, set, sorted set, stream, pub/sub and key tools use core Redis commands.
Python dependencies from pyproject.toml: mcp[cli] 1.26.0 or newer but below 2, redis 6.0.0 or newer, python-dotenv, numpy 2.2.4 or newer, click, aiohttp 3.13.0 or newer and redis-entraid 1.0.0 or newer. uv.lock pins specific versions, including mcp 1.30.0, redis 6.4.0, aiohttp 3.14.4 and redis-entraid 1.2.2. Entra ID needs Azure credentials of the chosen type: service principal, managed identity or default Azure credential. The docs search tool needs outbound HTTPS access to the documentation endpoint.
How it works
src/common/server.py creates a FastMCP server named Redis MCP Server and imports every module in src.tools. Each tool is an async function marked with the @mcp.tool() decorator. main.py defines a click command whose options cover the URL, host, port, database, username, password, TLS files, certificate requirements, cluster mode and several Entra ID settings. It then starts the server with mcp.run(), which uses stdio. Logging defaults to WARNING, and MCP_REDIS_LOG_LEVEL changes the level. If no logging handlers exist, the server adds one that writes to stderr. That keeps log lines off stdout, which is where the integration test reads protocol responses. If the host has already installed handlers, they keep their destinations, and the server only lowers handler thresholds that would hide the chosen level.
src/common/connection.py keeps one shared redis-py client. It creates a standard client, or a cluster client when cluster mode is on. The client allows up to 10 connections (10 per node in cluster mode) and includes the server version in its library name. If Entra ID is configured, a credential provider from redis-entraid gets and refreshes tokens. Tools catch Redis errors and return the error text as the tool result, so the model sees failures as messages.
Pub/sub runs through a SubscriptionManager that allows at most 50 active subscriptions. There is no background expiry timer. Cleanup happens only when a new subscription is stored: the manager looks for subscriptions idle for more than 300 seconds and tries to close them. Idle means not created or read in that time. If closing one fails, it is put back in the registry. Idle subscriptions therefore stay open until another subscription is created or they are explicitly unsubscribed. Only subscribe, psubscribe, read_messages and unsubscribe hand their subscription work to worker threads. publish, like the other Redis tools, calls the synchronous Redis client directly. read_messages accepts a polling timeout of at most 5000 ms and returns at most 100 messages per call. That 5000 ms is the largest polling timeout it accepts, not a cap on how long the call takes: SubscriptionManager starts the polling budget only after it acquires the subscription's lock, and waiting for that lock has no time limit. xreadgroup also rejects block times above 5000 ms, and rejects 0.
The source also shows four behaviours that are not obvious from the README. First, launching through the console script (the uvx path) without --url always passes the command line defaults for host, port, database, ssl and cluster mode into the configuration. Environment variables such as REDIS_HOST, REDIS_PORT, REDIS_DB, REDIS_SSL and REDIS_CLUSTER_MODE therefore appear to be replaced by those defaults. The same applies to Entra ID settings that have command line defaults: identity type, scopes, resource, refresh ratio and retry values. Running src/main.py directly calls a different function that does not read command line options, and then the environment variables are used. Second, config.py only treats the lowercase strings true, 1 and t as enabling SSL and cluster mode, so a value such as True is read as false. Third, the shared client is created once with whichever decode_responses setting the first caller requests. get_vector_from_hash asks for decode_responses=False, so the vector tools may misbehave depending on which tool is called first. Fourth, GEMINI.md describes REDIS_URL as the main environment variable, but config.py never reads it. It works only because gemini-extension.json passes ${REDIS_URL} to the --url option. These points follow from the source; runtime behaviour has not been verified.
Setup
The README recommends adding the server to your MCP client configuration so the client launches it with uvx, which downloads the package when needed. The command is uvx --from redis-mcp-server@latest redis-mcp-server --url redis://localhost:6379/0. For encrypted connections, use a rediss:// URL. Add the ssl_cert_reqs and ssl_ca_certs query parameters to verify the server; ssl_cert_reqs=none turns verification off. The README also describes three other routes. You can run a tagged GitHub release with uvx, or clone the repository and use uv run src/main.py. You can also build the included Dockerfile (docker build -t mcp-redis .) and launch it with docker run -i, passing REDIS_HOST, REDIS_PORT, REDIS_USERNAME and REDIS_PWD as environment variables. The README also mentions an official Docker Hub image (mcp/redis); that image is not among the captured files and its contents are unknown.
The README gives client-specific snippets for Claude Desktop, VS Code (mcp.json, with agent mode enabled), Augment and the OpenAI Agents SDK (examples/redis_assistant.py). The first JSON snippet in the README wraps the URL in escaped quotes inside the args list. If a client passes those quotes through literally, the URL parser in config.py finds no valid scheme and main.py exits with an error. Use the unquoted form shown in the other snippets. Passwords placed in URLs, command line arguments or client JSON are stored as plain text on your machine. gemini-extension.json marks its REDIS_URL setting as sensitive.
Because @latest always fetches the newest release, consider pinning a version for reproducible behaviour. For installs from GitHub, the README itself recommends tagged releases because main is under active development. The README also suggests connecting as a restricted Redis ACL user, for example one limited to read commands. For visual debugging it suggests the MCP Inspector (npx @modelcontextprotocol/inspector uv run src/main.py). None of these setup steps has been verified.
Example
The README gives this VS Code mcp.json entry: a server named redis, of type stdio, with command uvx and args --from redis-mcp-server@latest redis-mcp-server --url redis://localhost:6379/0. You can optionally add -qq at the start of args so uvx does not write installation messages to stderr.
With that configured, a user could ask the assistant: Store this session data with a 1-hour expiration. According to src/tools/string.py, the assistant would call the set tool with a key, a value and expiration 3600. The value can be a string, a number or a dict, and dicts are stored as JSON text. The tool uses Redis SETEX and returns a confirmation such as Successfully set <key> with expiration 3600 seconds. A request for the top scores on a leaderboard would map to zrange on a sorted set. A request to find similar items would map to vector_search_hash, where the caller must supply the query vector as a list of numbers. This describes what the code is written to do, not a recorded run.
Assessment & evidence
Limitations and risks
Access control: the server has no read-only or allow-list mode. Tools such as delete, rename, json_del, xdel, xgroup_destroy, lpop and rpop change data, and the assistant decides when to call them. The only restriction described is a Redis ACL on the user you connect as. Data read from Redis is returned into the model's context, so stored text can contain instructions aimed at the model. Treat this as the usual MCP prompt-injection risk.
Output size: scan_all_keys collects every matching key in memory. hgetall, smembers, lrange, info and client_list return whole results with no cap. On large databases these can flood the model's context. Data privacy: search_redis_documents sends the question text to the configured documentation endpoint over HTTP(S), so keep private data out of those questions.
Gaps: transport is stdio only, and one server process uses a single Redis connection configuration. Several tools handle one value per call, including sadd, srem, zadd and hset. Expiration applies to the whole key: the string set tool uses SETEX, while several other write tools issue a separate EXPIRE after writing. Stream and sorted-set results come back as Python string representations rather than structured data. There are no tools for other Redis features such as geospatial data, time series or probabilistic structures, although the docs search description mentions geospatial use cases.
Vector and search: the server does not create embeddings, so the caller must supply lists of numbers. create_vector_index_hash defines only a vector field on hash keys. hybrid_search filters on tag, numeric or text fields, as in the tool's own examples, need an index that includes those fields, and this server cannot create one. The shared-client decode_responses behaviour described under How it works could also affect vector retrieval.
Configuration: the mismatches described under How it works could lead to connecting with unintended settings, including silently without TLS. They are the environment-variable precedence, the lowercase-only true/false parsing and the undocumented handling of REDIS_URL. Testing: the tool unit tests use mocked Redis connections, and several tools have no matching unit test. tests/tools/test_misc.py covers only search_redis_documents, so delete, type, expire, rename, scan_keys and scan_all_keys have no unit tests, and get_indexed_keys_number has none either. The integration test starts the real server process and checks initialisation and the tool list. However, the captured tests do not run the tools against a live Redis, or exercise the JSON, search or Entra ID paths end to end. Runtime behaviour and test outcomes have not been verified.
Why these conclusions
The positive findings rest on direct evidence of working structure. The tool modules have typed signatures and docstrings and are registered with FastMCP. An integration test fixes the tool count at 53 and checks the names, and unit tests cover many tools using mocked Redis connections. The subscription manager caps subscriptions at 50, and read_messages and xreadgroup reject timeout values above 5000 ms, with xreadgroup also rejecting a block time of 0. An Entra ID provider factory validates its configuration. The release workflow is set up to build the package, run bandit and the tests, publish with build attestations and update the MCP registry entry.
The cautions rest on specific code paths. The environment override follows from main.py always building a configuration from click options that have defaults and passing it to set_redis_config_from_cli. The lowercase-only parsing comes from the fixed tuple of accepted strings in config.py. The REDIS_URL problem comes from config.py having no lookup for it while GEMINI.md documents one. The lack of a read-only mode is shown by the tool list and by the README recommending ACLs as the control. These conclusions come from the source, tests and documentation. Runtime behaviour has not been verified and should be confirmed in your own environment.
Alternatives and when not to use it
If your application accesses Redis in fixed, predictable ways, calling redis-py (or your language's Redis client) directly from your own code gives predictable behaviour with no model in the loop. An MCP server adds value mainly when you want an assistant to decide which operations to run. For manual exploration, redis-cli or a database GUI keeps a human in control of every command. The evidence contains no comparison with other MCP servers for Redis or for databases in general, so no ranking is offered.
Within this project, the README offers several install routes: PyPI via uvx, a GitHub tag, a local clone, a self-built Docker image, and a Docker Hub image it names mcp/redis. The choice mostly affects how updates arrive and how isolated the server is. Avoid pointing it at a production database with a fully privileged user. Also avoid it when you need remote or multi-user access to a shared MCP endpoint, since only stdio is supported.
Evidence base
The evidence base is every captured file in the selected scope. That includes the README, pyproject.toml and the full src tree: main, config, connection, entraid_auth, logging_utils, server, subscription_manager, version and eleven tool modules. It includes the test suite: config, connection, Entra ID, main, server, logging, integration and one test module per tool module. It also includes the CI, release and stale-issue workflows, the Dependabot settings, the Dockerfile, .dockerignore, .gitignore and .env.example. The rest are server.json, the Gemini extension files, fly.toml, the example agent, uv.lock and the MIT LICENSE.
The tool unit tests replace the Redis connection with a mock, and the documentation search tests replace the HTTP session instead. The integration test starts the server process and checks the initialize response and the 53-tool list. The CI workflow is set up to run ruff lint and format checks, a bandit security scan and pytest, and pyproject.toml adds an 80 percent coverage threshold to pytest runs. The configured test matrix covers Python 3.10 to 3.14 on Ubuntu with a Redis service container, and on Windows and macOS without one. CI is also set up to start src/main.py briefly as a smoke test, build and check the package, and build the Docker image. Run history, coverage figures and pass or fail status are not in the evidence, so whether these checks pass is unknown. Runtime behaviour of the server has not been verified.
Access & freshness
Costs
The software itself is distributed under the MIT licence, and the evidence shows no price, licence fee or paid tier for the server. Other costs depend on things outside the captured files, and their amounts are unknown. The first is the Redis deployment you connect to. The README and GEMINI.md mention self-hosted Redis, Redis Cloud, AWS ElastiCache, Azure Cache for Redis and Azure Managed Redis as targets, with no pricing in the evidence. The others are the AI client or model you use to drive the tools, and any token usage from large tool results.
By default the documentation search tool calls a Redis-hosted HTTP endpoint. The evidence contains no pricing, rate limits or terms for it, so those are unknown. fly.toml describes a Fly.io app with 1 GB of memory and one shared CPU in region sin. Its purpose is not explained and no cost is stated. Any Fly.io charges are unknown and only apply if you choose to deploy that way.
Rights and licence
The LICENSE file is the standard MIT licence with the notice Copyright (c) 2025, Redis, inc., and pyproject.toml declares license MIT. The licence permits using, copying, modifying, merging, publishing, distributing, sublicensing and selling the software. The condition is that the copyright and permission notice stay with all copies or substantial portions. The software comes without warranty. The README's licence badge links to ./LICENSE.txt, but the captured file is named LICENSE, which looks like a small documentation slip.
The captured files do not record the licences of the third-party dependencies pinned in uv.lock, so those licences are unknown. Any terms of use for the Redis documentation search endpoint, Docker Hub images, Azure services or the MCP registry are not in the evidence and are also unknown. No contributor licence agreement or trademark policy appears in the captured files.
Freshness
The content was captured on 12 November 2026 at commit d66c5ea0172e0991a98c0f13c0f880246c93b2a5. The Python package declares version 0.5.1 in pyproject.toml, src/version.py and uv.lock. Commit dates, release dates and issue history are not in the evidence, so the date of the last release and how actively the project is maintained are unknown. uv.lock pins dependency releases uploaded as late as 18 October 2026, including aiohttp 3.14.4, redis-entraid 1.2.2, black 26.10.1 and certifi 2026.10.18. The lock file was therefore generated on or after that date. The CI workflow is set up with a nightly scheduled run, and Dependabot is set to check pip, GitHub Actions and Docker dependencies weekly. These schedules show how the project is configured, not that recent runs succeeded.
The Gemini extension manifest declares version 0.1.0, while the Python package declares 0.5.1. server.json contains a $VERSION placeholder that the release workflow replaces with the release version when publishing. The stale-issue workflow is set to dry-run, so it does not close issues. fly.toml says it was generated on 24 July 2025. The README says the main branch is under active development and may contain breaking changes, so behaviour can change between releases.
Suggested next steps
To try it, start against a throwaway local Redis. Connect as a dedicated Redis user created with an ACL, read-only at first, for example using the ACL SETUSER command in the README. Pin a released version instead of @latest, and use an unquoted URL. Use lowercase true or false for any boolean environment variable. When launching through uvx, pass --url or the full set of command line options so the server uses the settings you intend. Check which Redis edition provides the JSON and search commands you plan to use.
Before relying on it for vector search, confirm how your client supplies embeddings, and create any filterable index fields outside the server. If you use Azure Entra ID with a user-assigned managed identity through the console script, set the identity type with its command line option and verify the connection. Watch the repository's releases for changes. Re-check the points flagged here against the version you install: environment precedence, REDIS_URL handling and the shared connection's decode setting. These were inferred from the source and have not been verified at runtime.
