Strava MCP Server
Connects to the Strava API to allow retrieval of athlete statistics, listing of recent activities, and fetching detailed information for specific activity IDs.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Strava MCP Servershow me my last five activities and career stats"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Strava MCP Server
A Model Context Protocol (MCP) server that connects to the Strava API, allowing AI agents to retrieve athlete stats, list activities, and get detailed activity information.
Prerequisites
Python 3.10+
uv (installed and available in your PATH)
Strava API Application (to get Client ID and Secret)
Related MCP server: Strava Training MCP
Setup
1. Credentials
Go to Strava API Settings.
Create an application if you haven't already.
Note your
Client IDandClient Secret.You need a Refresh Token.
The easiest way to get one for your own account is to use the Strava OAuth playground or follow the Strava authentication docs to authorize your app and get the initial refresh token.
Scope required:
activity:read_all,read_all(adjust based on needs).
2. Installation
Clone this repository and enter the directory.
Using uv (Recommended):
uv sync
source .venv/bin/activateUsing standard pip:
python -m venv .venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
pip install .3. Configuration
Copy
.env.exampleto.env.Fill in your credentials.
cp .env.example .env
# Edit .env with your favorite editorUsage
Run the server using fastmcp:
fastmcp run server.pyOr run it directly with uv:
uv run server.pyAvailable Tools
get_athlete_stats: Get statistics for the authenticated athlete.list_activities: List recent activities (default limit: 5).get_activity_details: Get detailed information for a specific activity ID.get_activity_laps: Get lap breakdowns for an activity (lap splits with metrics like pace, HR, power).get_activity_streams: Get raw stream data (GPS, heart rate, power, cadence, etc.) for an activity.search_activities: Search activities with filters (name query, type, date range, distance range).
Experimental
analyze_data: Execute Python code to analyze Strava data safely using Monty.Note: This tool allows the agent to write and execute Python code in a secure, sandboxed environment to perform complex calculations on your data (e.g., "calculate average pace for runs over 10km").
Connect to Claude Desktop
To use this server with Claude Desktop securely (keeping your API keys in .env and not in the config file), add the following to your claude_desktop_config.json:
Mac: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
You can use uv directly to run the server:
{
"mcpServers": {
"strava": {
"command": "uv",
"args": [
"run",
"server.py"
],
"cwd": "/absolute/path/to/strava-mcp"
}
}
}Note: Replace /absolute/path/to/strava-mcp with the full absolute path to your project directory. If Claude Desktop fails to start the server, you may need to provide the absolute path to the uv executable (e.g., /Users/yourname/.cargo/bin/uv). Run which uv (macOS/Linux) or where uv (Windows) in your terminal to find it.
Development
Running Tests
To run the test suite:
# Install dev dependencies
uv sync --extra dev
# Run tests
uv run pytest testsModify
server.pyto add more tools using thestravalibclient.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables interaction with Strava's API to access and manage activities, athlete data, routes, segments, clubs, and gear through natural language.2221MIT
- Alicense-qualityDmaintenanceProvides comprehensive access to Strava API for marathon training and race analysis, enabling language models to query athlete data, analyze training patterns, track performance metrics, monitor heart rate zones, and detect injury risks.1MIT
- AlicenseBqualityDmaintenanceIntegrates with the Strava API to allow AI assistants to access fitness data including athlete profiles, activity history, and segment statistics. It enables users to query detailed performance metrics and explore geographic segment data through natural language commands.853MIT
- AlicenseBqualityDmaintenanceEnables users to interact with their Strava data through natural language to analyze workouts, track fitness progress, and explore routes. It supports retrieving detailed activity stats, heart rate data, and segment insights directly within AI assistants.26262MIT
Related MCP Connectors
Garmin data in Claude: 135 tools — activities, sleep, HRV, training, workouts. Free, open source.
Garmin data in Claude & ChatGPT via the Garmin Health API. OAuth sign-in, no password sharing.
Gateway between LLM agents and world data through eight tools and a bundled endpoint catalog.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/saxenanurag/strava-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server