# tshark-mcp

> tshark-mcp is an open-source MCP server for developer tools. Read-only packet capture analysis with tshark, including Diameter, GTP and SIP. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI
- **Repository:** https://github.com/kx96xx/tshark-mcp
- **MCP Registry name:** io.github.Kx96xx/tshark-mcp
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools), [analytics and data](https://ai-powered.com/categories/analytics-and-data)
- **Listing updated:** 2026-11-18

## About

Point it at a folder of pcap files and ask what went wrong. An incident_summary tool runs every check the capture's protocols allow, ranks the findings and suggests the next call, and every claim cites frame numbers that can be opened in Wireshark.

Beyond DNS, TCP and TLS problems, it pairs requests with answers across Diameter, GTP, PFCP, SIP, RTP, SIGTRAN and MAP, names cause codes with their 3GPP references and can follow one subscriber across protocols. The author says it was built by a mobile core engineer, and reports testing against 102 public captures with 1,064 tool calls.

It is deliberately constrained: no shell, no live capture, and no writes except an optional export_subset directory you enable. The server refuses to start unless TSHARK_MCP_ALLOW_DIRS is set, applies caps on size, packets, output and time, and can pseudonymise IMSIs, phone numbers and IPs. It has 63 tools, with 34 in the default set, and needs tshark 4.0 or newer.

## Features

- **Incident summary:** Ranks findings from a capture and names the next call.
- **Telecom protocols:** Covers Diameter, GTP, PFCP, SIP, RTP, SIGTRAN and MAP.
- **Frame-numbered answers:** Each claim points to frames you can open in Wireshark.
- **Restricted access:** Reads only files inside allowed directories under hard caps.
- **Optional redaction:** Pseudonymises identifiers and optionally every IP address.
- **Subscriber tracing:** Follows one subscriber across protocols.

## Good for

- Find why a Diameter or GTP session failed
- Diagnose one-way audio in a SIP/RTP call
- Investigate slow servers or TLS and DNS errors
- Share captures with an assistant with identifiers redacted

## Install

### Claude Code (Terminal)

```sh
claude mcp add tshark-mcp --env TSHARK_MCP_ALLOW_DIRS='<TSHARK_MCP_ALLOW_DIRS>' -- uvx tshark-mcp-server
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "tshark-mcp": {
      "command": "uvx",
      "args": [
        "tshark-mcp-server"
      ],
      "env": {
        "TSHARK_MCP_ALLOW_DIRS": "<TSHARK_MCP_ALLOW_DIRS>"
      }
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "tshark-mcp": {
      "command": "uvx",
      "args": [
        "tshark-mcp-server"
      ],
      "env": {
        "TSHARK_MCP_ALLOW_DIRS": "<TSHARK_MCP_ALLOW_DIRS>"
      }
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "tshark-mcp": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "tshark-mcp-server"
      ],
      "env": {
        "TSHARK_MCP_ALLOW_DIRS": "<TSHARK_MCP_ALLOW_DIRS>"
      }
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "tshark-mcp": {
      "command": "uvx",
      "args": [
        "tshark-mcp-server"
      ],
      "env": {
        "TSHARK_MCP_ALLOW_DIRS": "<TSHARK_MCP_ALLOW_DIRS>"
      }
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "tshark-mcp": {
      "command": "uvx",
      "args": [
        "tshark-mcp-server"
      ],
      "env": {
        "TSHARK_MCP_ALLOW_DIRS": "<TSHARK_MCP_ALLOW_DIRS>"
      }
    }
  }
}
```

## Tools

- `incident_summary`: Runs the applicable checks, ranks findings and suggests the next call.
- `export_subset`: Writes a filtered pcapng to the enabled export directory.

## FAQ

### Can it capture live traffic?

No. It only runs tshark -r on existing files.

### What do I need installed?

uv and tshark 4.0 or newer.

### How many tools does it have?

63, with a default set of 34 to keep the list short.

### What licence is it?

MIT.

### Is tshark-mcp free?

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

### How do I add tshark-mcp to Claude Code?

Run this command in your terminal: claude mcp add tshark-mcp --env TSHARK_MCP_ALLOW_DIRS='<TSHARK_MCP_ALLOW_DIRS>' -- uvx tshark-mcp-server

### What are the best alternatives to tshark-mcp?

The closest alternatives to tshark-mcp 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.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Context7](https://ai-powered.com/mcp/context7): Context7 is a freemium MCP server for developer tools.
- [Chrome DevTools MCP](https://ai-powered.com/mcp/chrome-devtools-mcp-2): Chrome DevTools MCP is an open-source MCP server for browser automation.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github-2): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [awesome-mcp-servers](https://ai-powered.com/mcp/awesome-mcp-servers-2): awesome-mcp-servers is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.

---
Source: https://ai-powered.com/mcp/tshark-mcp
