# mcpstat - Usage Tracking for MCP Servers > Python observability for MCP servers: local SQLite-backed usage, outcome, token, > and latency statistics for instrumented tools, prompts, and resources. Use `pip install mcpstat` for the SDK-independent library in an existing Python server. Use `pip install "mcpstat[server]"` for the MCP SDK v2 integration and bundled stdio server. The bundled server tracks its own calls; it does not observe other servers. Register `get_tool_usage_stats` and `get_tool_catalog` in each instrumented server to query its data from an MCP client. Only cumulative `all time` reporting is supported. The bundled server and examples disable inbound SDK tracing; local statistics remain enabled. ## Documentation - [Overview](https://mcpstat.vadim.dev/index.md): features, use cases, and integration choices. - [Quick start](https://mcpstat.vadim.dev/quickstart.md): installation and complete high-level and low-level SDK integrations. - [Weather walkthrough](https://mcpstat.vadim.dev/quickstart.md#verify-mcp-tool-usage-with-a-weather-server): real MCP requests, successful and failed calls, unused tools, and restart persistence. - [API reference](https://mcpstat.vadim.dev/api.md): recording, decorators, queries, catalog, and SDK tracing controls. - [Configuration](https://mcpstat.vadim.dev/configuration.md): storage, logging, input limits, privacy, SDK tracing, and migration. - [Token tracking](https://mcpstat.vadim.dev/token-tracking.md): actual token reporting and estimates. - [Latency tracking](https://mcpstat.vadim.dev/latency-tracking.md): duration samples, averages, and limits. - [Privacy](https://mcpstat.vadim.dev/privacy.md): local library data and separate website analytics. ## Reference and Examples - [Full agent reference](https://mcpstat.vadim.dev/llms-full.txt): detailed integration guidance, tool schemas, tags, and API summaries. - [Weather server](https://raw.githubusercontent.com/tekkidev/mcpstat/main/examples/weather_server.py): synthetic high-level server with usage statistics. - [Weather client](https://raw.githubusercontent.com/tekkidev/mcpstat/main/examples/check_weather.py): reproducible stdio requests and counter assertions. - [Full integration example](https://raw.githubusercontent.com/tekkidev/mcpstat/main/examples/example_server.py): low-level tools, prompts, resources, and analytics. - [PyPI](https://pypi.org/project/mcpstat/): package releases and installation metadata. - [Source and issues](https://github.com/tekkidev/mcpstat): MIT-licensed source, contributions, and support.