MCP Toolbox for Databases vs Redis MCP Server
In short
MCP Toolbox for Databases vs Redis MCP Server: both are coding tools on Scriptiii AI Tools. MCP Toolbox for Databases pricing: Free. Free to use. (reported by the maker) Redis MCP Server pricing: Free. Free to use. (reported by the maker) Both have 0 upvotes.
- MCP Toolbox for Databases
- Free. Free to use. (reported by the maker)
- Redis MCP Server
- Free. Free to use. (reported by the maker)
- Upvotes
- 0 vs 0
| Field | MCP Toolbox for Databases | Redis MCP Server |
|---|---|---|
| Page | MCP Toolbox for Databases | Redis MCP Server |
| Pricing (maker-reported) | Free. Free to use. | Free. Free to use. |
| Upvotes | 0 | 0 |
| Best for | ai-agents, mcp-server, databases | ai-agents, mcp-server, databases |
| Tagline | Google open-source MCP server for connecting agents to databases such as Postgres, MySQL and BigQuery. | Official Redis MCP server providing a natural-language interface to store, manage and search data in Redis. |
| Website | Visit MCP Toolbox for Databases | Visit Redis MCP Server |
Pricing and pricing details come from the maker's submission. They are not independently verified.
MCP Toolbox for Databases
MCP Toolbox for Databases is an open source Model Context Protocol (MCP) server that connects your AI agents, IDEs, and applications directly to your enterprise databases.
It serves a dual purpose:
- Ready-to-use MCP Server (Build-Time): Instantly connect Gemini CLI, Google Antigravity, Claude Code, Codex, or other MCP clients to your databases using our prebuilt generic tools. Talk to your data, explore schemas, and generate code without writing boilerplate.
- Custom Tools Framework (Run-Time): A robust framework to build specialized, highly secure AI tools for your production agents. Define structured queries, semantic search, and NL2SQL capabilities safely and easily.
This README provides a brief overview. For comprehensive details, see the full documentation.
[!IMPORTANT]
Repository Name Update: Thegenai-toolboxrepository has been officially renamed tomcp-toolbox. To ensure your local environment reflects the new name, you may update your remote:
git remote set-url origin https://github.com/googleapis/mcp-toolbox.git
[!NOTE]
This solution was originally named “Gen AI Toolbox for Databases” (github.com/googleapis/genai-toolbox) as its initial development predated MCP, but was renamed to align with the MCP compatibility.
Table of Contents
- Why MCP Toolbox?
- Quick Start: Prebuilt Tools
- Quick Start: Custom Tools
- Install & Run the Toolbox server
- Connect to Toolbox
- Additional Features
- Versioning
- Contributing
- Community
Why MCP Toolbox?
- Out-of-the-Box Database Access: Prebuilt generic tools for instant data exploration (e.g.,
list_tables,execute_sql) directly from your IDE or CLI. - Custom Tools Framework: Build production-ready tools with your own predefined logic, ensuring safety through Restricted Access, Structured Queries, and Semantic Search.
- Simplified Development: Integrate tools into your Agent Development Kit (ADK), LangChain, LlamaIndex, or custom agents in less than 10 lines of code.
- Better Performance: Handles connection pooling, integrated auth (IAM), and end-to-end observability (OpenTelemetry) out of the box.
- Enhanced Security: Integrated authentication for more secure access to your data.
- End-to-end Observability: Out of the box metrics and tracing with built-in support for OpenTelemetry.
Quick Start: Prebuilt Tools
Stop context-switching and let your AI assistant become a true co-developer. By connecting your IDE to your databases with MCP Toolbox, you can query your data in plain English, automate schema discovery and management, and generate database-aware code.
You can use the Toolbox in any MCP-compatible IDE or client (e.g., Gemini CLI, Google Antigravity, Claude Code, Codex, etc.) by configuring the MCP server.
Prebuilt tools are also conveniently available via the Google Antigravity MCP Store with a simple click-to-install experience.
-
Add the following to your client's MCP configuration file (usually
mcp.jsonorclaude_desktop_config.json):{ "mcpServers": { "toolbox-postgres": { "command": "npx", "args": [ "-y", "@toolbox-sdk/server", "--prebuilt=postgres", "--stdio" ] } } } -
Set the appropriate environment variables to connect, see the Prebuilt Tools Reference.
When you run Toolbox with a --prebuilt=<database> flag, you instantly get access to standard tools to interact with that database. You can also specify a specific toolset using the --prebuilt=<database>/<toolset> syntax (e.g., --prebuilt=postgres/data to only load SQL tools).
Supported databases currently include:
- Google Cloud: AlloyDB, BigQuery, Cloud SQL (PostgreSQL, MySQL, SQL Server), Spanner, Firestore, Knowledge Catalog (formerly known as Dataplex).
- Other Databases: PostgreSQL, MySQL, MariaDB, SQL Server, Oracle, MongoDB, Redis, Elasticsearch, CockroachDB, ClickHouse, Couchbase, Neo4j, Snowflake, Trino, and more.
For a full list of available tools and their capabilities across all supported databases, see the Prebuilt Tools Reference.
See the Install & Run the Toolbox server section for different execution methods like Docker or binaries.
[!TIP]
For users looking for a managed solution, Google Cloud MCP Servers
provide a managed MCP experience with prebuilt tools; you can learn more about the differences here.
Quick Start: Custom Tools
Toolbox can also be used as a framework for customized tools.
The primary way to configure Toolbox is through the tools.yaml file. If you
have multiple files, you can tell Toolbox which to load with the --config tools.yaml flag.
You can find more detailed reference documentation to all resource types in the
Resources.
Sources
The sources section of your tools.yaml defines what data sources your
Toolbox should have access to. Most tools will have at least one source to
execute against.
kind: source
name: my-pg-source
type: postgres
host: 127.0.0.1
port: 5432
database: toolbox_db
user: toolbox_user
password: my-password
For more details on configuring different types of sources, see the
Sources.
Tools
The tools section of a tools.yaml define the actions an agent can take: what
type of tool it is, which source(s) it affects, what parameters it uses, etc.
kind: tool
name: search-hotels-by-name
type: postgres-sql
source: my-pg-source
description: Search for hotels based on name.
parameters:
- name: name
type: string
description: The name of the hotel.
statement: SELECT * FROM hotels WHERE name ILIKE '%' || $1 || '%';
For more details on configuring different types of tools, see the
Tools.
Toolsets
The toolsets section of your tools.yaml allows you to define groups of tools
that you want to be able to load together. This can be useful for defining
different groups based on agent or application.
kind: toolset
name: my_first_toolset
tools:
- my_first_tool
- my_second_tool
---
kind: toolset
name: my_second_toolset
tools:
- my_second_tool
- my_third_tool
Prompts
The prompts section of a tools.yaml defines prompts that can be used for
interactions with LLMs.
kind: prompt
name: code_review
description: "Asks the LLM to analyze code quality and suggest improvements."
messages:
- content: >
Please review the following code for quality, correctness,
and potential improvements: \n\n{{.code}}
arguments:
- name: "code"
description: "The code to review"
For more details on configuring prompts, see the
Prompts.
Resources
The resources and resourceTemplates sections of your tools.yaml define read-only
content, files, or parameterized directory trees that can be discovered and retrieved
by MCP clients:
kind: resource
name: database_schema_ddl
type: text
description: "Core table definitions and constraints."
mimeType: text/x-sql
text: |
CREATE TABLE customers (
id SERIAL PRIMARY KEY,
name VARCHAR(255) NOT NULL,
email VARCHAR(255) UNIQUE NOT NULL
);
---
kind: resource
name: database_schema
type: file
description: "PostgreSQL schema definition."
path: "./schema.sql"
---
kind: resourceTemplate
name: server_logs
type: file
description: "Application log files."
uriTemplate: "file:///var/log/{path}"
allowedPaths:
- "/var/log"
For more details on configuring resources and resource templates, see
Resources.
Install & Run the Toolbox server
You can run Toolbox directly with a configuration file:
npx @toolbox-sdk/server --config tools.yaml
This runs the latest version of the Toolbox server with your configuration file.
[!NOTE]
This method is optimized for convenience rather than performance.
For a more standard and reliable installation, please use the binary
or container image as described in Install & Run the Toolbox server.
Install Toolbox
For the latest version, check the releases page and use the
following instructions for your OS and CPU architecture.
Binary
To install Toolbox as a binary:
Linux (AMD64)
To install Toolbox as a binary on Linux (AMD64):
# see releases page for other versions export VERSION=1.16.0 curl -L -o toolbox https://storage.googleapis.com/mcp-toolbox-for-databases/v$VERSION/linux/amd64/toolbox chmod +x toolboxmacOS (Apple Silicon)
To install Toolbox as a binary on macOS (Apple Silicon):
# see releases page for other versions export VERSION=1.16.0 curl -L -o toolbox https://storage.googleapis.com/mcp-toolbox-for-databases/v$VERSION/darwin/arm64/toolbox chmod +x toolboxmacOS (Intel)
To install Toolbox as a binary on macOS (Intel):
# see releases page for other versions export VERSION=1.16.0 curl -L -o toolbox https://storage.googleapis.com/mcp-toolbox-for-databases/v$VERSION/darwin/amd64/toolbox chmod +x toolboxWindows (Command Prompt)
To install Toolbox as a binary on Windows (Command Prompt):
:: see releases page for other versions set VERSION=1.16.0 curl -o toolbox.exe "https://storage.googleapis.com/mcp-toolbox-for-databases/v%VERSION%/windows/amd64/toolbox.exe"Windows (PowerShell)
To install Toolbox as a binary on Windows (PowerShell):
# see releases page for other versions $VERSION = "1.16.0" curl.exe -o toolbox.exe "https://storage.googleapis.com/mcp-toolbox-for-databases/v$VERSION/windows/amd64/toolbox.exe"Windows ARM64 (Command Prompt)
To install Toolbox as a binary on Windows ARM64 (Command Prompt):
:: see releases page for other versions set VERSION=1.16.0 curl -o toolbox.exe "https://storage.googleapis.com/mcp-toolbox-for-databases/v%VERSION%/windows/arm64/toolbox.exe"Windows ARM64 (PowerShell)
To install Toolbox as a binary on Windows ARM64 (PowerShell):
# see releases page for other versions $VERSION = "1.16.0" curl.exe -o toolbox.exe "https://storage.googleapis.com/mcp-toolbox-for-databases/v$VERSION/windows/arm64/toolbox.exe"
Container image
You can also install Toolbox as a container:## see releases page for other versions
export VERSION=1.16.0
docker pull us-central1-docker.pkg.dev/database-toolbox/toolbox/toolbox:$VERSION
Homebrew
To install Toolbox using Homebrew on macOS or Linux:
brew install mcp-toolbox
Compile from source
To install from source, ensure you have the latest version of
Go installed, and then run the following command:
go install github.com/googleapis/mcp-toolbox@v1.16.0
Gemini CLI
Check out the [Gemini CLI extensions](https://geminicli.com/extensions/) to install prebuilt tools for specific databases like AlloyDB, BigQuery, and Cloud SQL directly into Gemini CLI.## Install Gemini CLI
npm install -g @google/gemini-cli
## Install the extension
gemini extensions install https://github.com/gemini-cli-extensions/cloud-sql-postgres
## Run Gemini CLI
gemini
Interact with your custom tools using natural language through the Gemini CLI.
## Install the extension
gemini extensions install https://github.com/gemini-cli-extensions/mcp-toolbox
Run Toolbox
Configure a tools.yaml to define your tools, and then
execute toolbox to start the server:
Binary
To run Toolbox from binary:
./toolbox --config "tools.yaml"
ⓘ Note
Toolbox enables dynamic reloading by default. To disable, use the
--disable-reloadflag.
Container image
To run the server after pulling the container image:
export VERSION=0.24.0 # Use the version you pulled
docker run -p 5000:5000 \
-v $(pwd)/tools.yaml:/app/tools.yaml \
us-central1-docker.pkg.dev/database-toolbox/toolbox/toolbox:$VERSION \
--config "/app/tools.yaml"
ⓘ Note
The-vflag mounts your localtools.yamlinto the container, and-pmaps
the container's port5000to your host's port5000.
Source
To run the server directly from source, navigate to the project root directory
and run:
go run .
ⓘ Note
This command runs the project from source, and is more suitable for development
and testing. It does not compile a binary into your$GOPATH. If you want
to compile a binary instead, refer the Developer
Documentation.
Homebrew
If you installed Toolbox using Homebrew, the toolbox
binary is available in your system path. You can start the server with the same
command:
toolbox --config "tools.yaml"
NPM
To run Toolbox directly without manually downloading the binary (requires Node.js):
npx @toolbox-sdk/server --config tools.yaml
Gemini CLI
After installing a [Gemini CLI extensions](https://geminicli.com/extensions/), the prebuilt tools will be available during use.## Run Gemini CLI
gemini
## List extensions
/extensions list
## List MCP servers
/mcp list
You can use toolbox help for a full list of flags! To stop the server, send a
terminate signal (ctrl+c on most platforms).
For more detailed documentation on deploying to different environments, check
out the resources in the Deploy Toolbox
section
Connect to Toolbox
Once your Toolbox server is up and running, you can load tools into your MCP-compatible client or
application.
MCP Client
Add the following configuration to your MCP client configuration:
{
"mcpServers": {
"toolbox": {
"type": "http",
"url": "http://127.0.0.1:5000/mcp",
}
}
}
If you would like to connect to a specific toolset, replace url with "http://127.0.0.1:5000/mcp/{toolset_name}".
Toolbox SDKs: Integrate with your Application
Toolbox Client SDKs provide the easy-to-use building blocks and advanced features for connecting your custom applications to the MCP Toolbox server. See below the list of Client SDKs for using various frameworks:
Python (Github)
Core
Install Toolbox Core SDK:
pip install toolbox-coreLoad tools:
from toolbox_core import ToolboxClient # update the url to point to your server async with ToolboxClient("http://127.0.0.1:5000") as client: # these tools can be passed to your application! tools = await client.load_toolset("toolset_name")For more detailed instructions on using the Toolbox Core SDK, see the
project's README.LangChain / LangGraph
Install Toolbox LangChain SDK:
pip install toolbox-langchainLoad tools:
from toolbox_langchain import ToolboxClient # update the url to point to your server async with ToolboxClient("http://127.0.0.1:5000") as client: # these tools can be passed to your application! tools = client.load_toolset()For more detailed instructions on using the Toolbox LangChain SDK, see the
project's README.LlamaIndex
Install Toolbox Llamaindex SDK:
pip install toolbox-llamaindexLoad tools:
from toolbox_llamaindex import ToolboxClient # update the url to point to your server async with ToolboxClient("http://127.0.0.1:5000") as client: # these tools can be passed to your application! tools = client.load_toolset()For more detailed instructions on using the Toolbox Llamaindex SDK, see the
project's README.
Javascript/Typescript (Github)
Core
Install Toolbox Core SDK:
npm install @toolbox-sdk/coreLoad tools:
import { ToolboxClient } from '@toolbox-sdk/core'; // update the url to point to your server const URL = 'http://127.0.0.1:5000'; let client = new ToolboxClient(URL); // these tools can be passed to your application! const tools = await client.loadToolset('toolsetName');For more detailed instructions on using the Toolbox Core SDK, see the
project's README.LangChain / LangGraph
Install Toolbox Core SDK:
npm install @toolbox-sdk/coreLoad tools:
import { ToolboxClient } from '@toolbox-sdk/core'; // update the url to point to your server const URL = 'http://127.0.0.1:5000'; let client = new ToolboxClient(URL); // these tools can be passed to your application! const toolboxTools = await client.loadToolset('toolsetName'); // Define the basics of the tool: name, description, schema and core logic const getTool = (toolboxTool) => tool(currTool, { name: toolboxTool.getName(), description: toolboxTool.getDescription(), schema: toolboxTool.getParamSchema() }); // Use these tools in your Langchain/Langraph applications const tools = toolboxTools.map(getTool);Genkit
Install Toolbox Core SDK:
npm install @toolbox-sdk/coreLoad tools:
import { ToolboxClient } from '@toolbox-sdk/core'; import { genkit } from 'genkit'; // Initialise genkit const ai = genkit({ plugins: [ googleAI({ apiKey: process.env.GEMINI_API_KEY || process.env.GOOGLE_API_KEY }) ], model: googleAI.model('gemini-2.0-flash'), }); // update the url to point to your server const URL = 'http://127.0.0.1:5000'; let client = new ToolboxClient(URL); // these tools can be passed to your application! const toolboxTools = await client.loadToolset('toolsetName'); // Define the basics of the tool: name, description, schema and core logic const getTool = (toolboxTool) => ai.defineTool({ name: toolboxTool.getName(), description: toolboxTool.getDescription(), schema: toolboxTool.getParamSchema() }, toolboxTool) // Use these tools in your Genkit applications const tools = toolboxTools.map(getTool);ADK
Install Toolbox ADK SDK:
npm install @toolbox-sdk/adkLoad tools:
import { ToolboxClient } from '@toolbox-sdk/adk'; // update the url to point to your server const URL = 'http://127.0.0.1:5000'; let client = new ToolboxClient(URL); // these tools can be passed to your application! const tools = await client.loadToolset('toolsetName');For more detailed instructions on using the Toolbox ADK SDK, see the
project's README.
Go (Github)
Core
Install Toolbox Go SDK:
go get github.com/googleapis/mcp-toolbox-sdk-goLoad tools:
package main import ( "github.com/googleapis/mcp-toolbox-sdk-go/core" "context" ) func main() { // Make sure to add the error checks // update the url to point to your server URL := "http://127.0.0.1:5000"; ctx := context.Background() client, err := core.NewToolboxClient(URL) // Framework agnostic tools tools, err := client.LoadToolset("toolsetName", ctx) }For more detailed instructions on using the Toolbox Go SDK, see the
project's README.LangChain Go
Install Toolbox Go SDK:
go get github.com/googleapis/mcp-toolbox-sdk-goLoad tools:
package main import ( "context" "encoding/json" "github.com/googleapis/mcp-toolbox-sdk-go/core" "github.com/tmc/langchaingo/llms" ) func main() { // Make sure to add the error checks // update the url to point to your server URL := "http://127.0.0.1:5000" ctx := context.Background() client, err := core.NewToolboxClient(URL) // Framework agnostic tool tool, err := client.LoadTool("toolName", ctx) // Fetch the tool's input schema inputschema, err := tool.InputSchema() var paramsSchema map[string]any _ = json.Unmarshal(inputschema, ¶msSchema) // Use this tool with LangChainGo langChainTool := llms.Tool{ Type: "function", Function: &llms.FunctionDefinition{ Name: tool.Name(), Description: tool.Description(), Parameters: paramsSchema, }, } }Genkit
Install Toolbox Go SDK:
go get github.com/googleapis/mcp-toolbox-sdk-goLoad tools:
package main import ( "context" "log" "github.com/firebase/genkit/go/genkit" "github.com/googleapis/mcp-toolbox-sdk-go/core" "github.com/googleapis/mcp-toolbox-sdk-go/tbgenkit" ) func main() { // Make sure to add the error checks // Update the url to point to your server URL := "http://127.0.0.1:5000" ctx := context.Background() g := genkit.Init(ctx) client, err := core.NewToolboxClient(URL) // Framework agnostic tool tool, err := client.LoadTool("toolName", ctx) // Convert the tool using the tbgenkit package // Use this tool with Genkit Go genkitTool, err := tbgenkit.ToGenkitTool(tool, g) if err != nil { log.Fatalf("Failed to convert tool: %v\n", err) } log.Printf("Successfully converted tool: %s", genkitTool.Name()) }Go GenAI
Install Toolbox Go SDK:
go get github.com/googleapis/mcp-toolbox-sdk-goLoad tools:
package main import ( "context" "encoding/json" "github.com/googleapis/mcp-toolbox-sdk-go/core" "google.golang.org/genai" ) func main() { // Make sure to add the error checks // Update the url to point to your server URL := "http://127.0.0.1:5000" ctx := context.Background() client, err := core.NewToolboxClient(URL) // Framework agnostic tool tool, err := client.LoadTool("toolName", ctx) // Fetch the tool's input schema inputschema, err := tool.InputSchema() var schema *genai.Schema _ = json.Unmarshal(inputschema, &schema) funcDeclaration := &genai.FunctionDeclaration{ Name: tool.Name(), Description: tool.Description(), Parameters: schema, } // Use this tool with Go GenAI genAITool := &genai.Tool{ FunctionDeclarations: []*genai.FunctionDeclaration{funcDeclaration}, } }OpenAI Go
Install Toolbox Go SDK:
go get github.com/googleapis/mcp-toolbox-sdk-goLoad tools:
package main import ( "context" "encoding/json" "github.com/googleapis/mcp-toolbox-sdk-go/core" openai "github.com/openai/openai-go" ) func main() { // Make sure to add the error checks // Update the url to point to your server URL := "http://127.0.0.1:5000" ctx := context.Background() client, err := core.NewToolboxClient(URL) // Framework agnostic tool tool, err := client.LoadTool("toolName", ctx) // Fetch the tool's input schema inputschema, err := tool.InputSchema() var paramsSchema openai.FunctionParameters _ = json.Unmarshal(inputschema, ¶msSchema) // Use this tool with OpenAI Go openAITool := openai.ChatCompletionToolParam{ Function: openai.FunctionDefinitionParam{ Name: tool.Name(), Description: openai.String(tool.Description()), Parameters: paramsSchema, }, } }ADK Go
Install Toolbox Go SDK:
go get github.com/googleapis/mcp-toolbox-sdk-goLoad tools:
package main import ( "github.com/googleapis/mcp-toolbox-sdk-go/tbadk" "context" ) func main() { // Make sure to add the error checks // Update the url to point to your server URL := "http://127.0.0.1:5000" ctx := context.Background() client, err := tbadk.NewToolboxClient(URL) if err != nil { return fmt.Sprintln("Could not start Toolbox Client", err) } // Use this tool with ADK Go tool, err := client.LoadTool("toolName", ctx) if err != nil { return fmt.Sprintln("Could not load Toolbox Tool", err) } }For more detailed instructions on using the Toolbox Go SDK, see the
project's README.
Additional Features
Test tools with the Toolbox UI
To launch Toolbox's interactive UI, use the --ui flag. This allows you to test
tools and toolsets with features such as authorized parameters. To learn more,
visit Toolbox UI.
./toolbox --ui
Telemetry
Toolbox emits traces and metrics via OpenTelemetry. Use --telemetry-otlp=<endpoint>
to export to any OTLP-compatible backend like Google Cloud Monitoring, Agnost AI, or
others. See the telemetry docs for details.
Generate Agent Skills
The skills-generate command allows you to convert a toolset into an Agent Skill compatible with the Agent Skill specification. This is useful for distributing tools as portable skill packages.
toolbox --config tools.yaml skills-generate \
--name "my-skill" \
--toolset "my_toolset" \
--description "A skill containing multiple tools"
Once generated, you can install the skill into the Gemini CLI:
gemini skills install ./skills/my-skill
For more details, see the Generating Skills guide. To serve a skill you already have over MCP, see Serving Skills over MCP.
The repository also ships ready-to-use Agent Skills (e.g. maintainer workflows). See skills/ for the catalog and install instructions.
Versioning
MCP Toolbox for Databases follows Semantic Versioning.
The Public API includes the Toolbox Server (CLI, configuration manifests, and pre-built toolsets) and the Client SDKs.
- Major versions are incremented for breaking changes, such as incompatible CLI or manifest changes.
- Minor versions are incremented for new features, including modifications to pre-built toolsets or beta features.
- Patch versions are incremented for backward-compatible bug fixes.
For more details, including our Container Tagging Policy, see our Full Versioning Policy.
Contributing
Contributions are welcome. Please, see the CONTRIBUTING guide to get started.
For technical details on setting up a environment for developing on Toolbox itself, see the DEVELOPER guide.
Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms. See Contributor Code of Conduct for more information.
Community
Join our Discord community to connect with our developers!
Redis MCP Server
Redis MCP Server
Overview
The Redis MCP Server is a natural language interface designed for agentic applications to efficiently manage and search data in Redis. It integrates seamlessly with MCP (Model Content Protocol) clients, enabling AI-driven workflows to interact with structured and unstructured data in Redis. Using this MCP Server, you can ask questions like:
- "Store the entire conversation in a stream"
- "Cache this item"
- "Store the session with an expiration time"
- "Index and search this vector"
Table of Contents
- Overview
- Features
- Tools
- Installation
- Configuration
- Integrations
- Testing
- Example Use Cases
- Contributing
- License
- Badges
- Contact
Features
- Natural Language Queries: Enables AI agents to query and update Redis using natural language.
- Seamless MCP Integration: Works with any MCP client for smooth communication.
- Full Redis Support: Handles hashes, lists, sets, sorted sets, streams, and more.
- Search & Filtering: Supports efficient data retrieval and searching in Redis.
- Scalable & Lightweight: Designed for high-performance data operations.
- EntraID Authentication: Native support for Azure Active Directory authentication with Azure Managed Redis.
- The Redis MCP Server supports the
stdiotransport. Support to thestremable-httptransport will be added in the future.
Tools
This MCP Server provides tools to manage the data stored in Redis.
stringtools to set, get strings with expiration. Useful for storing simple configuration values, session data, or caching responses.hashtools to store field-value pairs within a single key. The hash can store vector embeddings. Useful for representing objects with multiple attributes, user profiles, or product information where fields can be accessed individually.listtools with common operations to append and pop items. Useful for queues, message brokers, or maintaining a list of most recent actions.settools to add, remove and list set members. Useful for tracking unique values like user IDs or tags, and for performing set operations like intersection.sorted settools to manage data for e.g. leaderboards, priority queues, or time-based analytics with score-based ordering.pub/subfunctionality to publish messages, create stateful channel or pattern subscriptions, and read queued messages using returned subscription handles. Useful for real-time notifications, chat applications, or distributing updates to multiple clients.streamstools to add, read, delete, create and destroy consumer groups, and acknowledge processed entries in data streams. Useful for event sourcing, activity feeds, and worker-based event processing with Redis Streams consumer groups.JSONtools to store, retrieve, and manipulate JSON documents in Redis. Useful for complex nested data structures, document databases, or configuration management with path-based access.
Additional tools.
docstool to search Redis documentation, tutorials, and best practices using natural language questions (backed by theMCP_DOCS_SEARCH_URLHTTP API).query enginetools to manage vector indexes and perform vector searchserver managementtool to retrieve information about the database
Installation
The Redis MCP Server is available as a PyPI package and as direct installation from the GitHub repository.
From PyPI (recommended)
Configuring the latest Redis MCP Server version from PyPI, as an example, can be done importing the following JSON configuration in the desired framework or tool.
The uvx command will download the server on the fly (if not cached already), create a temporary environment, and then run it.
{
"mcpServers": {
"RedisMCPServer": {
"command": "uvx",
"args": [
"--from",
"redis-mcp-server@latest",
"redis-mcp-server",
"--url",
"\"redis://localhost:6379/0\""
]
}
}
}
URL specification
The format to specify the --url argument follows the redis and rediss schemes:
redis://user:secret@localhost:6379/0?foo=bar&qux=baz
As an example, you can easily connect to a localhost server with:
redis://localhost:6379/0
Where 0 is the logical database you'd like to connect to.
For an encrypted connection to the database (e.g., connecting to a Redis Cloud database), you'd use the rediss scheme.
rediss://user:secret@localhost:6379/0?foo=bar&qux=baz
To verify the server's identity, specify ssl_ca_certs.
rediss://user:secret@hostname:port?ssl_cert_reqs=required&ssl_ca_certs=path_to_the_certificate
For an unverified connection, set ssl_cert_reqs to none
rediss://user:secret@hostname:port?ssl_cert_reqs=none
Configure your connection using the available options in the section "Available CLI Options".
Testing the PyPI package
You can install the package as follows:
pip install redis-mcp-server
And start it using uv the package in your environment.
uv python install 3.14
uv sync
uv run redis-mcp-server --url redis://localhost:6379/0
However, starting the MCP Server is most useful when delegate to the framework or tool where this MCP Server is configured.
From GitHub
You can configure the desired Redis MCP Server version with uvx, which allows you to run it directly from GitHub (from a branch, or use a tagged release).
It is recommended to use a tagged release, the
mainbranch is under active development and may contain breaking changes.
As an example, you can execute the following command to run the 0.2.0 release:
uvx --from git+https://github.com/redis/mcp-redis.git@0.2.0 redis-mcp-server --url redis://localhost:6379/0
Check the release notes for the latest version in the Releases section.
Additional examples are provided below.
## Run with Redis URI
uvx --from git+https://github.com/redis/mcp-redis.git redis-mcp-server --url redis://localhost:6379/0
## Run with Redis URI and SSL
uvx --from git+https://github.com/redis/mcp-redis.git redis-mcp-server --url "rediss://<USERNAME>:<PASSWORD>@<HOST>:<PORT>?ssl_cert_reqs=required&ssl_ca_certs=<PATH_TO_CERT>"
## Run with individual parameters
uvx --from git+https://github.com/redis/mcp-redis.git redis-mcp-server --host localhost --port 6379 --password mypassword
## See all options
uvx --from git+https://github.com/redis/mcp-redis.git redis-mcp-server --help
Development Installation
For development or if you prefer to clone the repository:
## Clone the repository
git clone https://github.com/redis/mcp-redis.git
cd mcp-redis
## Install dependencies using uv
uv venv
source .venv/bin/activate
uv sync
## Run with CLI interface
uv run redis-mcp-server --help
## Or run the main file directly (uses environment variables)
uv run src/main.py
Once you cloned the repository, installed the dependencies and verified you can run the server, you can configure Claude Desktop or any other MCP Client to use this MCP Server running the main file directly (it uses environment variables). This is usually preferred for development.
The following example is for Claude Desktop, but the same applies to any other MCP Client.
- Specify your Redis credentials and TLS configuration
- Retrieve your
uvcommand full path (e.g.which uv) - Edit the
claude_desktop_config.jsonconfiguration file- on a MacOS, at
~/Library/Application\ Support/Claude/
- on a MacOS, at
{
"mcpServers": {
"redis": {
"command": "<full_path_uv_command>",
"args": [
"--directory",
"<your_mcp_server_directory>",
"run",
"src/main.py"
],
"env": {
"REDIS_HOST": "<your_redis_database_hostname>",
"REDIS_PORT": "<your_redis_database_port>",
"REDIS_PWD": "<your_redis_database_password>",
"REDIS_SSL": True|False,
"REDIS_SSL_CA_PATH": "<your_redis_ca_path>",
"REDIS_CLUSTER_MODE": True|False
}
}
}
}
You can troubleshoot problems by tailing the log file.
tail -f ~/Library/Logs/Claude/mcp-server-redis.log
With Docker
You can use a dockerized deployment of this server. You can either build your own image or use the official Redis MCP Docker image.
If you'd like to build your own image, the Redis MCP Server provides a Dockerfile. Build this server's image with:
docker build -t mcp-redis .
Finally, configure the client to create the container at start-up. An example for Claude Desktop is provided below. Edit the claude_desktop_config.json and add:
{
"mcpServers": {
"redis": {
"command": "docker",
"args": ["run",
"--rm",
"--name",
"redis-mcp-server",
"-i",
"-e", "REDIS_HOST=<redis_hostname>",
"-e", "REDIS_PORT=<redis_port>",
"-e", "REDIS_USERNAME=<redis_username>",
"-e", "REDIS_PWD=<redis_password>",
"mcp-redis"]
}
}
}
To use the official Redis MCP Docker image, just replace your image name (mcp-redis in the example above) with mcp/redis.
Configuration
The Redis MCP Server can be configured in two ways: via command line arguments or via environment variables.
The precedence is: command line arguments > environment variables > default values.
Redis ACL
You can configure Redis ACL to restrict the access to the Redis database. For example, to create a read-only user:
127.0.0.1:6379> ACL SETUSER readonlyuser on >mypassword ~* +@read -@write
Configure the user via command line arguments or environment variables.
Configuration via command line arguments
When using the CLI interface, you can configure the server with command line arguments:
## Basic Redis connection
uvx --from redis-mcp-server@latest redis-mcp-server \
--host localhost \
--port 6379 \
--password mypassword
## Using Redis URI (simpler)
uvx --from redis-mcp-server@latest redis-mcp-server \
--url redis://user:pass@localhost:6379/0
## SSL connection
uvx --from redis-mcp-server@latest redis-mcp-server \
--url rediss://user:pass@redis.example.com:6379/0
## See all available options
uvx --from redis-mcp-server@latest redis-mcp-server --help
Available CLI Options:
--url- Redis connection URI (redis://user:pass@host:port/db)--host- Redis hostname (default: 127.0.0.1)--port- Redis port (default: 6379)--db- Redis database number (default: 0)--username- Redis username--password- Redis password--ssl- Enable SSL connection--ssl-ca-path- Path to CA certificate file--ssl-keyfile- Path to SSL key file--ssl-certfile- Path to SSL certificate file--ssl-cert-reqs- SSL certificate requirements (default: required)--ssl-ca-certs- Path to CA certificates file--cluster-mode- Enable Redis cluster mode
Configuration via Environment Variables
If desired, you can use environment variables. Defaults are provided for all variables.
| Name | Description | Default Value |
|---|---|---|
REDIS_HOST | Redis IP or hostname | "127.0.0.1" |
REDIS_PORT | Redis port | 6379 |
REDIS_DB | Database | 0 |
REDIS_USERNAME | Default database username | "default" |
REDIS_PWD | Default database password | "" |
REDIS_SSL | Enables or disables SSL/TLS | False |
REDIS_SSL_CA_PATH | CA certificate for verifying server | None |
REDIS_SSL_KEYFILE | Client's private key file for client authentication | None |
REDIS_SSL_CERTFILE | Client's certificate file for client authentication | None |
REDIS_SSL_CERT_REQS | Whether the client should verify the server's certificate | "required" |
REDIS_SSL_CA_CERTS | Path to the trusted CA certificates file | None |
REDIS_CLUSTER_MODE | Enable Redis Cluster mode | False |
EntraID Authentication for Azure Managed Redis
The Redis MCP Server supports EntraID (Azure Active Directory) authentication for Azure Managed Redis, enabling OAuth-based authentication with automatic token management.
Authentication Providers
Service Principal Authentication - Application-based authentication using client credentials:
export REDIS_ENTRAID_AUTH_FLOW=service_principal
export REDIS_ENTRAID_CLIENT_ID=your-client-id
export REDIS_ENTRAID_CLIENT_SECRET=your-client-secret
export REDIS_ENTRAID_TENANT_ID=your-tenant-id
Managed Identity Authentication - For Azure-hosted applications:
## System-assigned managed identity
export REDIS_ENTRAID_AUTH_FLOW=managed_identity
export REDIS_ENTRAID_IDENTITY_TYPE=system_assigned
## User-assigned managed identity
export REDIS_ENTRAID_AUTH_FLOW=managed_identity
export REDIS_ENTRAID_IDENTITY_TYPE=user_assigned
export REDIS_ENTRAID_USER_ASSIGNED_CLIENT_ID=your-identity-client-id
Default Azure Credential - Automatic credential discovery (recommended for development):
export REDIS_ENTRAID_AUTH_FLOW=default_credential
export REDIS_ENTRAID_SCOPES=https://redis.azure.com/.default
EntraID Configuration Variables
| Name | Description | Default Value |
|---|---|---|
REDIS_ENTRAID_AUTH_FLOW | Authentication flow type | None (EntraID disabled) |
REDIS_ENTRAID_CLIENT_ID | Service Principal client ID | None |
REDIS_ENTRAID_CLIENT_SECRET | Service Principal client secret | None |
REDIS_ENTRAID_TENANT_ID | Azure tenant ID | None |
REDIS_ENTRAID_IDENTITY_TYPE | Managed identity type | "system_assigned" |
REDIS_ENTRAID_USER_ASSIGNED_CLIENT_ID | User-assigned managed identity client ID | None |
REDIS_ENTRAID_SCOPES | OAuth scopes for Default Azure Credential | "https://redis.azure.com/.default" |
REDIS_ENTRAID_RESOURCE | Azure Redis resource identifier | "https://redis.azure.com/" |
Key Features
- Automatic token renewal - Background token refresh with no manual intervention
- Graceful fallback - Falls back to standard Redis authentication when EntraID not configured
- Multiple auth flows - Supports Service Principal, Managed Identity, and Default Azure Credential
- Enterprise ready - Designed for Azure Managed Redis with centralized identity management
Example Configuration
For local development with Azure CLI:
## Login with Azure CLI
az login
## Configure MCP server
export REDIS_ENTRAID_AUTH_FLOW=default_credential
export REDIS_URL=redis://your-azure-redis.redis.cache.windows.net:6379
For production with Service Principal:
export REDIS_ENTRAID_AUTH_FLOW=service_principal
export REDIS_ENTRAID_CLIENT_ID=your-app-client-id
export REDIS_ENTRAID_CLIENT_SECRET=your-app-secret
export REDIS_ENTRAID_TENANT_ID=your-tenant-id
export REDIS_URL=redis://your-azure-redis.redis.cache.windows.net:6379
For Azure-hosted applications with Managed Identity:
export REDIS_ENTRAID_AUTH_FLOW=managed_identity
export REDIS_ENTRAID_IDENTITY_TYPE=system_assigned
export REDIS_URL=redis://your-azure-redis.redis.cache.windows.net:6379
There are several ways to set environment variables:
- Using a
.envFile:
Place a.envfile in your project directory with key-value pairs for each environment variable. Tools likepython-dotenv,pipenv, anduvcan automatically load these variables when running your application. This is a convenient and secure way to manage configuration, as it keeps sensitive data out of your shell history and version control (if.envis in.gitignore).
For example, create a.envfile with the following content from the.env.examplefile provided in the repository:
cp .env.example .env
Then edit the .env file to set your Redis configuration:
OR,
- Setting Variables in the Shell:
You can export environment variables directly in your shell before running your application. For example:
export REDIS_HOST=your_redis_host
export REDIS_PORT=6379
## Other variables will be set similarly...
This method is useful for temporary overrides or quick testing.
Logging
The server uses Python's standard logging and is configured at startup. By default it logs at WARNING and above. You can change verbosity with the MCP_REDIS_LOG_LEVEL environment variable.
- Accepted values (case-insensitive):
DEBUG,INFO,WARNING,ERROR,CRITICAL,NOTSET - Aliases supported:
WARN→WARNING,FATAL→CRITICAL - Numeric values are also accepted, including signed (e.g.,
"10","+20") - Default when unset or unrecognized:
WARNING
Handler behavior
- If the host (e.g.,
uv, VS Code, pytest) already installed console handlers, the server will NOT add its own; it only lowers overly-restrictive handler thresholds so your chosen level is not filtered out. It will never raise a handler's threshold. - If no handlers are present, the server adds a single stderr StreamHandler with a simple format.
Examples
## See normal lifecycle messages
MCP_REDIS_LOG_LEVEL=INFO uv run src/main.py
## Very verbose for debugging
MCP_REDIS_LOG_LEVEL=DEBUG uvx --from redis-mcp-server@latest redis-mcp-server --url redis://localhost:6379/0
In MCP client configs that support env, add it alongside your Redis settings. For example:
{
"mcpServers": {
"redis": {
"command": "uvx",
"args": ["--from", "redis-mcp-server@latest", "redis-mcp-server", "--url", "redis://localhost:6379/0"],
"env": {
"REDIS_HOST": "localhost",
"REDIS_PORT": "6379",
"MCP_REDIS_LOG_LEVEL": "INFO"
}
}
}
}
Integrations
Integrating this MCP Server to development frameworks like OpenAI Agents SDK, or with tools like Claude Desktop, VS Code, or Augment is described in the following sections.
OpenAI Agents SDK
Integrate this MCP Server with the OpenAI Agents SDK. Read the documents to learn more about the integration of the SDK with MCP.
Install the Python SDK.
pip install openai-agents
Configure the OpenAI token:
export OPENAI_API_KEY="<openai_token>"
And run the application.
python3.14 redis_assistant.py
You can troubleshoot your agent workflows using the OpenAI dashboard.
Augment
The preferred way of configuring the Redis MCP Server in Augment is to use the Easy MCP feature.
You can also configure the Redis MCP Server in Augment manually by importing the server via JSON:
{
"mcpServers": {
"Redis MCP Server": {
"command": "uvx",
"args": [
"--from",
"redis-mcp-server@latest",
"redis-mcp-server",
"--url",
"redis://localhost:6379/0"
]
}
}
}
Claude Desktop
The simplest way to configure MCP clients is using uvx. Add the following JSON to your claude_desktop_config.json, remember to provide the full path to uvx.
Basic Redis connection:
{
"mcpServers": {
"redis-mcp-server": {
"type": "stdio",
"command": "/Users/mortensi/.local/bin/uvx",
"args": [
"--from", "redis-mcp-server@latest",
"redis-mcp-server",
"--url", "redis://localhost:6379/0"
]
}
}
}
Azure Managed Redis with EntraID authentication:
{
"mcpServers": {
"redis-mcp-server": {
"type": "stdio",
"command": "/Users/mortensi/.local/bin/uvx",
"args": [
"--from", "redis-mcp-server@latest",
"redis-mcp-server",
"--url", "redis://your-azure-redis.redis.cache.windows.net:6379"
],
"env": {
"REDIS_ENTRAID_AUTH_FLOW": "default_credential",
"REDIS_ENTRAID_SCOPES": "https://redis.azure.com/.default"
}
}
}
}
VS Code with GitHub Copilot
To use the Redis MCP Server with VS Code, you must nable the agent mode tools. Add the following to your settings.json:
{
"chat.agent.enabled": true
}
You can start the GitHub desired version of the Redis MCP server using uvx by adding the following JSON to your mcp.json file:
"servers": {
"redis": {
"type": "stdio",
"command": "uvx",
"args": [
"--from", "redis-mcp-server@latest",
"redis-mcp-server",
"--url", "redis://localhost:6379/0"
]
},
}
Suppressing uvx Installation Messages
If you want to suppress uvx installation messages that may appear as warnings in MCP client logs, use the -qq flag:
"servers": {
"redis": {
"type": "stdio",
"command": "uvx",
"args": [
"-qq",
"--from", "redis-mcp-server@latest",
"redis-mcp-server",
"--url", "redis://localhost:6379/0"
]
},
}
The -qq flag enables silent mode, which suppresses "Installed X packages" messages that uvx writes to stderr during package installation.
Alternatively, you can start the server using uv and configure your mcp.json. This is usually desired for development.
// mcp.json
{
"servers": {
"redis": {
"type": "stdio",
"command": "<full_path_uv_command>",
"args": [
"--directory",
"<your_mcp_server_directory>",
"run",
"src/main.py"
],
"env": {
"REDIS_HOST": "<your_redis_database_hostname>",
"REDIS_PORT": "<your_redis_database_port>",
"REDIS_USERNAME": "<your_redis_database_username>",
"REDIS_PWD": "<your_redis_database_password>",
}
}
}
}
For more information, see the VS Code documentation.
Tip: You can prompt Copilot chat to use the Redis MCP tools by including
#redisin your message.
Note: Starting with VS Code v1.102,
MCP servers are now stored in a dedicatedmcp.jsonfile instead ofsettings.json.
Testing
You can use the MCP Inspector for visual debugging of this MCP Server.
npx @modelcontextprotocol/inspector uv run src/main.py
Example Use Cases
- AI Assistants: Enable LLMs to fetch, store, and process data in Redis.
- Chatbots & Virtual Agents: Retrieve session data, manage queues, and personalize responses.
- Data Search & Analytics: Query Redis for real-time insights and fast lookups.
- Event Processing: Manage event streams with Redis Streams.
Contributing
- Fork the repo
- Create a new branch (
feature-branch) - Commit your changes
- Push to your branch and submit a PR!
License
This project is licensed under the MIT License.
Badges
Contact
For questions or support, reach out via GitHub Issues.
Alternatively, you can join the Redis Discord server and ask in the #redis-mcp-server channel.
Questions
- Do MCP Toolbox for Databases and Redis MCP Server list the same price?
- Both listings report Free. Free to use. Pricing is reported by the maker and is not independently verified.
- Which has more upvotes, MCP Toolbox for Databases or Redis MCP Server?
- Both have 0 upvotes.
- What does each maker say MCP Toolbox for Databases and Redis MCP Server are for?
- MCP Toolbox for Databases: Google open-source MCP server for connecting agents to databases such as Postgres, MySQL and BigQuery. Redis MCP Server: Official Redis MCP server providing a natural-language interface to store, manage and search data in Redis.
MCP Toolbox for Databases alternatives·Redis MCP Server alternatives·All coding tools