Back to MCP Catalog

Redis Database Manager MCP Server

DatabasesJavaScript
Interact with Redis databases through standardized tools
Available Tools

set

Set a Redis key-value pair with optional expiration

keyvalueexpireSeconds

get

Get value by key from Redis

key

delete

Delete one or more keys from Redis

key

list

List Redis keys matching a pattern

pattern

Redis Database Manager provides a standardized interface for LLMs to interact with Redis key-value stores. This implementation enables AI assistants to perform common Redis operations like setting values, retrieving data, deleting keys, and listing database contents. With this tool, developers can seamlessly integrate Redis database operations into their AI workflows, allowing for persistent storage and retrieval of information across sessions. The server supports optional expiration times for stored values and pattern matching for key retrieval.

Installation

You can install the Redis Database Manager in several ways:

Using Smithery (Recommended for Claude Desktop)

The easiest way to install is via Smithery:

npx -y @smithery/cli install @gongrzhe/server-redis-mcp --client claude

Using NPX

You can run the server directly with npx:

npx @gongrzhe/server-redis-mcp@1.0.0 redis://your-redis-host:port

For example:

npx @gongrzhe/server-redis-mcp@1.0.0 redis://localhost:6379

Global Installation

Alternatively, you can install the package globally:

npm install -g @gongrzhe/server-redis-mcp@1.0.0

Then run it:

@gongrzhe/server-redis-mcp redis://your-redis-host:port

Configuration

Claude Desktop Configuration

To use this server with Claude Desktop, add the following to your claude_desktop_config.json:

{
  "mcpServers": {
    "redis": {
      "command": "npx",
      "args": [
        "@gongrzhe/server-redis-mcp@1.0.0",
        "redis://localhost:6379"
      ]
    }
  }
}

Replace redis://localhost:6379 with your Redis server URL.

Docker Configuration

If you're using Docker, you can configure it as follows:

{
  "mcpServers": {
    "redis": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "mcp/redis",
        "redis://host.docker.internal:6379"
      ]
    }
  }
}

Note: For macOS, use host.docker.internal if the Redis server is running on the host network.

Building from Source

If you want to build the server from source:

  1. Clone the repository
  2. Install dependencies: npm install
  3. Build the project: npm run build

Docker Build

To build a Docker image:

docker build -t mcp/redis .

Advanced Usage

The Redis Database Manager supports a variety of Redis operations through its tools. You can use these tools to store data persistently, retrieve information, and manage your Redis database directly through AI interactions.

For more advanced Redis functionality, check out the extended version with 62 Redis tools at: https://github.com/GongRzhe/REDIS-MCP-Server/tree/redis-plus

Related MCPs

Milvus Vector Database
DatabasesPython

Connect to Milvus vector database for semantic search and vector operations

MotherDuck DuckDB
DatabasesPython

SQL analytics with DuckDB and MotherDuck for AI assistants

Alibaba Cloud Tablestore
DatabasesJava, Python

Connect to Alibaba Cloud Tablestore for vector search and RAG applications

About Model Context Protocol

Model Context Protocol (MCP) allows AI models to access external tools and services, extending their capabilities beyond their training data.

Generate Cursor Documentation

Save time on coding by generating custom documentation and prompts for Cursor IDE.