Skip to content
MCP server

Monitor

BetterDB MCP server for Valkey and Redis health, slow commands and hot keys

Runs locally
Install
Pricing
Open source
Platforms
CLI, self-hosted
Runs
Locally
Version
1.6.0
Listing updated
4 days ago

Similar MCP servers

About Monitor

Monitor is an open-source MCP server for databases. It runs locally on your machine and is started by your AI client.

Unlike a live-only viewer, this server talks to a BetterDB monitor that keeps historical metrics, slowlogs and audit trails, so an assistant can look back at what happened yesterday. The npm package @betterdb/mcp runs over stdio and needs the monitor's URL and, for cloud, a token created under Settings, MCP Tokens.

The README lists health checks for memory fragmentation, hit rate and replication lag, slowlog and COMMANDLOG analysis, hot key detection, per-node cluster views, client activity, an ACL audit log and latency history. Anomaly detection by Z-score is marked Pro. An --autostart option can spawn a local monitor, and usage telemetry can be turned off with environment variables.

Install

Run in a terminal

claude mcp add monitor --env BETTERDB_TOKEN='<BETTERDB_TOKEN>' --env BETTERDB_LOCAL_TOKEN='<BETTERDB_LOCAL_TOKEN>' -- npx -y @betterdb/mcp

Add to claude_desktop_config.json

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

Add to ~/.cursor/mcp.json

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

Add to .vscode/mcp.json

{
  "servers": {
    "monitor": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@betterdb/mcp"
      ],
      "env": {
        "BETTERDB_TOKEN": "<BETTERDB_TOKEN>",
        "BETTERDB_LOCAL_TOKEN": "<BETTERDB_LOCAL_TOKEN>"
      }
    }
  }
}

Add to ~/.codeium/windsurf/mcp_config.json

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

Add to your client's MCP settings (most use this shape)

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

Using several servers? Build one config file with the MCP config generator.

Configuration

  • BETTERDB_URLURL of the BetterDB monitor instance
  • BETTERDB_TOKENMCP authentication token generated from the BetterDB Settings page
  • BETTERDB_INSTANCE_IDInstance ID to target when using multi-instance cloud deployments
  • BETTERDB_LOCAL_TOKENToken for a monitor started with --autostart or start_monitor when BETTERDB_URL is set to a different monitor; without it that monitor gets no token. BETTERDB_TOKEN is used when BETTERDB_URL is unset or points at the started monitor
  • BETTERDB_MCP_TELEMETRYSet to false, 0, no or off to stop posting tool usage events to the monitor. Usage events are off if this or BETTERDB_TELEMETRY is off
  • BETTERDB_TELEMETRYSet to false, 0, no or off to turn off telemetry for both the MCP server and a monitor it starts

Tools this server provides (3)

Taken from the project documentation; the running server may differ.

list_instances
List registered Valkey/Redis instances with connection status
select_instance
Select which instance later calls operate on
get_health
Synthetic health summary of an instance

What it does

Health summary
Synthetic health check covering memory fragmentation, hit rate and replication lag.
Slow command analysis
Reads slowlog and Valkey 8 COMMANDLOG with pattern aggregation.
Hot key detection
Finds hot keys using LFU frequency or idle time.
Cluster visibility
Per-node stats, aggregated slowlogs and slot-level metrics.
Anomaly detection
Z-score analysis on memory, CPU and hit rate; marked Pro.
ACL audit log
Investigate auth failures and access patterns.
Local autostart
Can spawn and manage a local monitor process.

Good for

  • Diagnose slow Valkey commands from the editor
  • Find hot keys causing uneven load
  • Check memory and replication health
  • Investigate cache hit rate of AI caches
  • Review ACL failures after an incident

Pricing

Open source

MIT licence; anomaly detection marked Pro, BetterDB Cloud also offered; prices not published

Monitor FAQ

How do I connect it?

Add an npx @betterdb/mcp entry with BETTERDB_URL and a token from Settings, MCP Tokens.

Is a token required?

Required for cloud; optional for self-hosted, where read tools work anonymously.

Can I run the monitor locally?

Yes, with --autostart, or by docker run of betterdb/monitor.

Can I turn telemetry off?

Yes, set BETTERDB_TELEMETRY to false, 0, no or off.

Is Monitor free?

Yes. Monitor is open source, so you can use and self-host it for free.

How do I add Monitor to Claude Code?

Run this command in your terminal: claude mcp add monitor --env BETTERDB_TOKEN='<BETTERDB_TOKEN>' --env BETTERDB_LOCAL_TOKEN='<BETTERDB_LOCAL_TOKEN>' -- npx -y @betterdb/mcp

What are the best alternatives to Monitor?

The closest alternatives to Monitor are REA, Context7, Chrome DevTools MCP, Codebase Memory and GitHub.

Where this comes from

  • Description: written from the project's README.
  • Install steps: from the official MCP Registry entry.

How AIPoweredBot checks servers