MCP Sniffer
About
MCP Sniffer captures network traffic between MCP clients and servers and displays it in a web UI.
Details
- Author
- shivdeepak
- GitHub stars
- 2
- Downloads
- 361
- Categories
- Other, Developer Tools
Jump to
- Acts as a reverse proxy between MCP client and server.
- Captures request and response payloads in real time.
- Web UI for visualizing captured traffic.
- Configurable listen, upstream, and web UI hosts/ports.
- Supports environment variables for all configuration options.
- Log level can be adjusted via --log-level.
Install via pipx install mcp-sniffer, then run the server using mcp-sniffer --listen-port <port> --upstream-port <port>. Configure host and port settings via command-line options or environment variables. Access the web UI at the default address http://127.0.0.1:8888.
MCP Sniffer
MCP Sniffer captures network traffic between MCP clients and servers.
It runs as a reverse proxy between the client and server, capturing request and response payloads that can be visualized in a web UI.
The following diagram shows how MCP Sniffer fits into the MCP Client-Server Model.

For the Web UI - Imagine Google Chrome DevTools' Network Tab for Model Context Protocol.
Following is a very early version of it.

Install
pipx install mcp-sniffer
Usage
$ mcp-sniffer --help
usage: mcp-sniffer [-h] [--listen-host LISTEN_HOST] [--listen-port LISTEN_PORT] [--upstream-host UPSTREAM_HOST]
[--upstream-port UPSTREAM_PORT] [--web-ui-host WEB_UI_HOST] [--web-ui-port WEB_UI_PORT]
[--log-level LOG_LEVEL]
MCP Sniffer
options:
-h, --help show this help message and exit
--listen-host LISTEN_HOST
Host to listen on (default: env LISTEN_HOST or 127.0.0.1)
--listen-port LISTEN_PORT
Port to listen on (default: env LISTEN_PORT or 3002)
--upstream-host UPSTREAM_HOST
Upstream host (default: env UPSTREAM_HOST or 127.0.0.1)
--upstream-port UPSTREAM_PORT
Upstream port (default: env UPSTREAM_PORT or 3001)
--web-ui-host WEB_UI_HOST
Web UI host (default: env WEB_UI_HOST or 127.0.0.1)
--web-ui-port WEB_UI_PORT
Web UI port (default: env WEB_UI_PORT or 8888)
--log-level LOG_LEVEL
Log level (default: env LOG_LEVEL or INFO)
Run
mcp-sniffer --listen-port 3002 --upstream-port 3001
INFO: Started server process [6174]
INFO: Waiting for application startup.
INFO: Application startup complete.
2025-04-27 19:52:53 devmachine.local mcp_sniffer.proxy[6174] INFO Listening on ('127.0.0.1', 3002)...
INFO: Uvicorn running on http://127.0.0.1:8888 (Press CTRL+C to quit)
Web UI
Visit http://127.0.0.1:8888.
Setup

Sign in to leave a review
Use Google, GitHub, or an email account so ratings stay tied to real people.
No reviews posted yet.





