Configure Visual Studio Code extensions to access your Netdata infrastructure through MCP.
The most popular open-source AI code assistant with MCP support.
Autonomous coding agent that can use MCP tools.
VS Code extensions typically support stdio-based MCP servers:
Note: Most VS Code extensions support stdio-based MCP servers. For HTTP/SSE connections to Netdata v2.7.2+, you can use npx mcp-remote bridge. For older Netdata versions (v2.6.0 - v2.7.1), use the nd-mcp bridge with WebSocket.
- VS Code installed - Download VS Code
- MCP-compatible extension - Install from VS Code Marketplace
- Netdata v2.6.0 or later with MCP support - Prefer a Netdata Parent to get infrastructure level visibility. Your AI Client (running on your desktop or laptop) needs to have direct network access to the Netdata IP and port (usually 19999).
- v2.6.0 - v2.7.1: Only WebSocket transport available, requires
nd-mcpbridge - v2.7.2+: Can use
npx mcp-remotebridge for HTTP/SSE support
- v2.6.0 - v2.7.1: Only WebSocket transport available, requires
- Bridge required: Choose one:
nd-mcpbridge - The stdio-to-websocket bridge for all Netdata versions. Find its absolute pathnpx mcp-remote@latest- Official MCP remote client supporting HTTP/SSE (requires Netdata v2.7.2+)
- Netdata MCP API key exported before launching VS Code - keep secrets out of config files by setting:
Each Netdata Agent or Parent has its own unique API key for MCP - Find your Netdata MCP API key
export ND_MCP_BEARER_TOKEN="$(cat /var/lib/netdata/mcp_dev_preview_api_key)"
Connect to your entire Netdata Cloud infrastructure through a single endpoint — no local setup, bridges, or firewall changes needed.
Prerequisites:
- Netdata Cloud account with Business plan
- Nodes claimed to Netdata Cloud
- API token with
scope:mcp(create one)
Add to .continue/mcpServers/netdata-cloud.yaml:
name: Netdata Cloud
version: 0.0.1
schema: v1
mcpServers:
- name: netdata-cloud
type: streamable-http
url: https://app.netdata.cloud/api/v1/mcp
requestOptions:
headers:
Authorization: Bearer YOUR_NETDATA_CLOUD_API_TOKENCline only supports stdio and SSE transports.
Since Netdata Cloud MCP uses Streamable HTTP,
you need the mcp-remote bridge to convert
stdio to HTTP:
{
"mcpServers": {
"netdata-cloud": {
"command": "npx",
"args": [
"mcp-remote@latest",
"https://app.netdata.cloud/api/v1/mcp",
"--header",
"Authorization: Bearer YOUR_NETDATA_CLOUD_API_TOKEN"
],
"alwaysAllow": [],
"disabled": false
}
}
}Replace YOUR_NETDATA_CLOUD_API_TOKEN with your
Netdata Cloud API token (must have scope:mcp).
For more details, see
Netdata Cloud MCP.
The following methods connect directly to a Netdata Agent or Parent on your network.
- Open VS Code
- Go to Extensions (Ctrl+Shift+X)
- Search for "Continue"
- Install the Continue extension
- Reload VS Code
- Click "Select model" dropdown at the bottom (next to Chat dropdown)
- Click "+ Add Chat model"
- In the configuration screen:
- Provider: Change to "Anthropic"
- Model: Select
Claude-3.5-Sonnet - API key: Enter your Anthropic API key
- Click "Connect"
Continue stores MCP definitions as YAML or JSON blocks. The recommended flow is:
- Click "MCP" in the Continue toolbar
- Click "+ Add MCP Servers" to scaffold
.continue/mcpServers/<name>.yaml - Replace the contents with one of the configurations below
Continue's reference guide documents the
typefield (stdio,sse, orstreamable-http) and block syntax (https://docs.continue.dev/customize/deep-dives/mcp).
Method 1: stdio launcher (all Netdata versions)
name: Netdata (nd-mcp)
version: 0.0.1
schema: v1
mcpServers:
- name: netdata
type: stdio
command: /usr/sbin/nd-mcp
args:
- ws://YOUR_NETDATA_IP:19999/mcpExport ND_MCP_BEARER_TOKEN before launching Continue so nd-mcp can authenticate without embedding secrets in YAML.
Method 2: Direct SSE (Netdata v2.7.2+)
name: Netdata (SSE)
version: 0.0.1
schema: v1
mcpServers:
- name: netdata
type: sse
url: https://YOUR_NETDATA_IP:19999/mcp
requestOptions:
headers:
Authorization: Bearer ${NETDATA_MCP_API_KEY}Method 3: Streamable HTTP (Netdata v2.7.2+)
name: Netdata (HTTP)
version: 0.0.1
schema: v1
mcpServers:
- name: netdata
type: streamable-http
url: https://YOUR_NETDATA_IP:19999/mcp
requestOptions:
headers:
Authorization: Bearer ${NETDATA_MCP_API_KEY}Continue expands environment placeholders such as ${NETDATA_MCP_API_KEY} so you can keep API keys out of source control. After saving, reload the window to pick up the new server.
Press Ctrl+L to open Continue chat, then:
@netdata what's the current CPU usage?
@netdata show me memory trends for the last hour
@netdata are there any anomalies in the database servers?
- Search for "Cline" in Extensions
- Install and reload VS Code
Cline's official docs describe two workflows (https://docs.cline.bot/mcp/configuring-mcp-servers):
- UI configuration – Click the MCP Servers icon → Configure tab → add/update servers, restart, toggle, and set timeouts.
- JSON configuration – Click Configure MCP Servers to open
cline_mcp_settings.jsonand edit the underlying JSON.
Stdio (nd-mcp)
{
"mcpServers": {
"netdata": {
"command": "/usr/sbin/nd-mcp",
"args": [
"ws://YOUR_NETDATA_IP:19999/mcp"
],
"alwaysAllow": [],
"disabled": false
}
}
}SSE for Netdata v2.7.2+
{
"mcpServers": {
"netdata": {
"url": "https://YOUR_NETDATA_IP:19999/mcp",
"headers": {
"Authorization": "Bearer NETDATA_MCP_API_KEY"
},
"alwaysAllow": [],
"disabled": false
}
}
}Optional fields such as
networkTimeout,alwaysAllow, andenvmap directly to Cline's UI controls. SSE and stdio are the two transports Cline supports today; pick the one that matches your Netdata deployment.
- Open Cline (Ctrl+Shift+P → "Cline: Open Chat")
- Cline can autonomously:
- Analyze performance issues
- Create monitoring scripts
- Debug based on metrics
Example:
Create a Python script that checks Netdata for high CPU usage and sends an alert
Create a YAML file in your project's .continue/mcpServers/ directory (e.g., netdata-prod.yaml):
name: Netdata Production
version: 0.0.1
schema: v1
mcpServers:
- name: netdata-prod
type: stdio
command: /usr/sbin/nd-mcp
args:
- ws://prod-parent:19999/mcpDifferent projects can have different Netdata connections:
~/projects/frontend/.continue/mcpServers/netdata.yaml→ Frontend servers~/projects/backend/.continue/mcpServers/netdata.yaml→ Backend servers~/projects/infrastructure/.continue/mcpServers/netdata.yaml→ All servers
ℹ️ Export
ND_MCP_BEARER_TOKENwith the appropriate key before opening VS Code so the bridge picks up credentials without storing them in the YAML files.
Create custom VS Code commands that query Netdata:
{
"commands": [
{
"command": "netdata.checkHealth",
"title": "Netdata: Check System Health"
}
]
}Add Netdata checks to tasks.json:
{
"version": "2.0.0",
"tasks": [
{
"label": "Check Production Metrics",
"type": "shell",
"command": "continue",
"args": [
"--ask",
"@netdata show current system status"
]
}
]
}Create snippets that include metric checks:
{
"Check Performance": {
"prefix": "perf",
"body": [
"// @netdata: Current ${1:CPU} usage?",
"$0"
]
}
}- Restart VS Code after configuration
- Check extension logs (Output → Continue/Cline)
- Verify JSON syntax in settings
- Test Netdata:
curl http://YOUR_NETDATA_IP:19999/api/v3/info - Check bridge is executable
- Verify network access from VS Code
- Ensure
@netdatais typed correctly - Check MCP server is configured
- Try reloading the window (Ctrl+R)
- Use local Netdata Parent for faster response
- Check extension memory usage
- Disable unused extensions
- Start coding with infrastructure context
- Check metrics before optimization
- Validate changes against production data
- Monitor impact of deployments
Share Netdata configurations:
- Commit
.vscode/settings.jsonfor project-specific configs - Document which Netdata Parent to use
- Create team snippets for common queries
