# BetterDB Monitor MCP server

> Inspect Valkey and Redis slowlogs, client activity, cluster state and anomalies from your AI assistant through a BetterDB instance.

- Listing: https://mcp.tc/i/betterdb-monitor
- Connect: this is a local (stdio) server; install it on your machine (see Install). The listing link is a page, not an MCP endpoint.
- Type: local (stdio)
- Auth: API key
- Category: [Observability & Incidents](https://mcp.tc/c/observability)
- Vendor: BetterDB Inc.
- Homepage: <https://betterdb.com>
- Repository: <https://github.com/BetterDB-inc/monitor/tree/HEAD/packages/mcp>
- Package: npm `@betterdb/mcp`

## About

Connects an MCP client to a BetterDB Monitor instance that tracks Valkey and Redis databases. BetterDB keeps slowlogs, command patterns, client activity, hot keys, cluster topology and anomaly signals, so an assistant can help debug what happened at a past point in time. The README lists 60 tools.

Runs locally as the npm package @betterdb/mcp over stdio, started with npx. It talks to a BetterDB Monitor instance whose address is set in BETTERDB\_URL. A token created under Settings, MCP Tokens is required on cloud deployments and optional on self-hosted ones.

## What it can do

- Query historical slowlogs and command patterns
- Inspect client activity and ACL audit trail
- Review hot keys and cluster topology
- Check anomaly detection and capacity forecasts
- Target a specific instance in multi-instance cloud setups

## Example prompts

- "Show the slowest Valkey commands from last night around 3am."
- "Which clients are generating the most load on my Valkey instance?"
- "List the current hot keys and how their rank changed."
- "Were there any anomalies on my Valkey cluster in the past day?"

## Install

### Claude Code

1. Run this in a terminal, in your project folder:

```bash
claude mcp add --transport stdio betterdb-monitor --env "BETTERDB_TOKEN=<YOUR_BETTERDB_TOKEN>" -- npx -y @betterdb/mcp
```

2. Start Claude Code and type `/mcp`. **betterdb-monitor** should show as connected.

Add `--scope user` to make it available in every project. Replace the placeholders with your own values.

### Claude Desktop

1. Open **Settings → Developer → Edit Config**. It opens `claude_desktop_config.json`. Add:

`claude_desktop_config.json`:

```json
{
  "mcpServers": {
    "betterdb-monitor": {
      "command": "npx",
      "args": [
        "-y",
        "@betterdb/mcp"
      ],
      "env": {
        "BETTERDB_TOKEN": "<YOUR_BETTERDB_TOKEN>"
      }
    }
  }
}
```

2. Save the file and restart Claude Desktop. Replace the placeholders with your own values.

Needs Node.js on your computer. The file lives in `~/Library/Application Support/Claude/` on macOS and `%APPDATA%\Claude\` on Windows.

### Cursor

[Add to Cursor](<https://cursor.com/install-mcp?name=betterdb-monitor&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsIkBiZXR0ZXJkYi9tY3AiXSwiZW52Ijp7IkJFVFRFUkRCX1RPS0VOIjoiPFlPVVJfQkVUVEVSREJfVE9LRU4%2BIn19>) (opens Cursor)

Or add it by hand to `~/.cursor/mcp.json` (all projects) or `.cursor/mcp.json` (this project):

`mcp.json`:

```json
{
  "mcpServers": {
    "betterdb-monitor": {
      "command": "npx",
      "args": [
        "-y",
        "@betterdb/mcp"
      ],
      "env": {
        "BETTERDB_TOKEN": "<YOUR_BETTERDB_TOKEN>"
      }
    }
  }
}
```

Needs Node.js on your computer. Replace the placeholders with your own values.

### VS Code

Add it to `.vscode/mcp.json`. VS Code asks for the secret the first time and stores it securely:

`.vscode/mcp.json`:

```json
{
  "servers": {
    "betterdb-monitor": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@betterdb/mcp"
      ],
      "env": {
        "BETTERDB_TOKEN": "${input:betterdb-token}"
      }
    }
  },
  "inputs": [
    {
      "type": "promptString",
      "id": "betterdb-token",
      "description": "BETTERDB_TOKEN",
      "password": true
    }
  ]
}
```

Needs Node.js on your computer.

### Devin Desktop

1. Add it to `~/.config/devin/mcp_config.json` (macOS and Linux) or `%APPDATA%\devin\mcp_config.json` (Windows):

`mcp_config.json`:

```json
{
  "mcpServers": {
    "betterdb-monitor": {
      "command": "npx",
      "args": [
        "-y",
        "@betterdb/mcp"
      ],
      "env": {
        "BETTERDB_TOKEN": "<YOUR_BETTERDB_TOKEN>"
      }
    }
  }
}
```

2. Refresh the MCP server list in Cascade. Replace the placeholders with your own values.

Devin Desktop is the new name for Windsurf.

### Codex

```bash
codex mcp add betterdb-monitor --env "BETTERDB_TOKEN=<YOUR_BETTERDB_TOKEN>" -- npx -y @betterdb/mcp
```

Or edit `~/.codex/config.toml` directly:

`config.toml`:

```toml
[mcp_servers.betterdb-monitor]
command = "npx"
args = ["-y", "@betterdb/mcp"]
env = { BETTERDB_TOKEN = "<YOUR_BETTERDB_TOKEN>" }
```

Needs Node.js on your computer. Replace the placeholders with your own values.

### Gemini CLI

```bash
gemini mcp add -e "BETTERDB_TOKEN=<YOUR_BETTERDB_TOKEN>" betterdb-monitor npx -- -y @betterdb/mcp
```

This adds it to the current project. Add `-s user` to use it everywhere.

### Any client

Most clients that start local servers accept this shape:

```json
{
  "mcpServers": {
    "betterdb-monitor": {
      "command": "npx",
      "args": [
        "-y",
        "@betterdb/mcp"
      ],
      "env": {
        "BETTERDB_TOKEN": "<YOUR_BETTERDB_TOKEN>"
      }
    }
  }
}
```

Zed puts servers under `context_servers` in its settings, with the same `command`, `args` and `env` fields.

Needs Node.js on your computer. Replace the placeholders with your own values.

## Recent changes

- 2026-11-10 17:31 UTC: New version 1.6.0 (was 1.5.0), read from npm. Source: automatic check.
- 2026-10-08 04:20 UTC: Tracking started: version 1.5.0. Source: automatic check.

More on the History tab, with descriptions before and after for the newest entries: https://mcp.tc/i/betterdb-monitor#history (Atom feed: https://mcp.tc/i/betterdb-monitor/history.xml). It records what mcp.tc's anonymous checks saw, every 3 hours where the tool list can be read without sign-in; it is not a security review.

## Details

- Server version: 1.6.0
- Last checked: 2026-10-08
- Listed: 2026-10-08
- Updated: 2026-10-08

---
Source: https://mcp.tc/i/betterdb-monitor (mcp.tc is an independent directory, not affiliated with this server's publisher). Corrections: https://mcp.tc/report
