This guide explains how to connect Gemini CLI to the Runalyze MCP Server so Gemini can access your Runalyze data through the Model Context Protocol (MCP).
Before you begin:
Note: The MCP server requires a valid Runalyze Premium account and a Personal API Token.
Open your Gemini CLI configuration file:
~/.gemini/settings.json
%USERPROFILE%\.gemini\settings.json
Add the following MCP server configuration:
{
"mcpServers": {
"runalyze": {
"httpUrl": "https://runalyze.com/mcp",
"headers": {
"Authorization": "Bearer YOUR_RUNALYZE_TOKEN"
},
"trust": true
}
}
}
Replace YOUR_RUNALYZE_TOKEN with the Bearer Token you generated in Runalyze.
Instead of storing the token directly in the configuration file, you can use an environment variable.
export RUNALYZE_API_TOKEN="your_bearer_token_here"
$env:RUNALYZE_API_TOKEN="your_bearer_token_here"
Then configure Gemini CLI like this:
{
"mcpServers": {
"runalyze": {
"httpUrl": "https://runalyze.com/mcp",
"headers": {
"Authorization": "Bearer ${RUNALYZE_API_TOKEN}"
},
"trust": true
}
}
}
Restart Gemini CLI after saving the configuration:
gemini
Inside Gemini CLI, run:
/mcp
You should see a connected MCP server named:
runalyze
Once connected, you can ask Gemini questions such as:
Show my last 10 running activities.
What was my average resting heart rate this month?
Summarize my training load for the last 4 weeks.
How has my HRV changed over the last 30 days?
/mcpsettings.json.Verify that the Authorization header is configured exactly as follows:
Authorization: Bearer <token>
Ensure that the MCP endpoint is reachable:
https://runalyze.com/mcp
and that your settings.json file contains valid JSON.
Please let us know if you have wishes or have encountered bugs. We give our best to make Runalyze as good as possible for you. - Therefore we would be interested in your suggestions for improvement. In general most questions, problems and ideas are more appropriate to ask in the forum.