Garmin makes it nearly impossible for individuals to access their own health data programmatically. There is no public API. The official "developer program" is restricted to approved businesses only.
Overview
Garmin makes it nearly impossible for individuals to access their own health data programmatically. There is no public API. The official "developer program" is restricted to approved businesses only.
README
garmin-givemydata (100% Working)
It’s YOUR data. Take it back. One command. All your Garmin data. Local SQLite + FIT files. Export to CSV, JSON, GPX, TCX. AI-ready via MCP.
Garmin makes it nearly impossible for individuals to access their own health data programmatically. There is no public API. The official “developer program” is restricted to approved businesses only. And in March 2026, Garmin deployed aggressive Cloudflare protections that broke every single community library — garth (deprecated), python-garminconnect (broken auth), and all downstream tools like Home Assistant integrations.
You paid for the hardware. You generated the data with your body. You should be able to access it.
This project gets your data out of Garmin Connect and into a local SQLite database where you own it and AI can analyze it through an MCP server for Claude Code.
50 tables, 10+ years of history, 45 MCP tools for AI analysis. Your data stays on your machine.
The Problem
- No public API: Garmin’s Connect Developer Program requires a business application. Individual developers are denied.
- garth is dead: The most popular auth library was deprecated on March 28, 2026 after Garmin changed their SSO flow.
- Bot detection: Garmin deployed aggressive bot detection that blocks all known Python HTTP libraries. Every existing workaround stopped working.
- python-garminconnect is broken: Depends on garth for auth. Issue #332 has 40+ comments from affected users.
- Connect+ paywall: Garmin launched a $7/month subscription and is restricting third-party access to features that compete with it.
Nobody should buy Garmin products until they open their API to the people who paid for the hardware.
Quick Start
Install
# macOS
brew install nrvim/tap/garmin-givemydata
# pip (Linux / Windows / macOS)
pip install garmin-givemydata
# or clone
git clone https://github.com/nrvim/garmin-givemydata.git
cd garmin-givemydata
bash setup.sh # macOS / Linux
setup.bat # Windows
Fetch your data
garmin-givemydata # fetches all historical data + FIT files
First run prompts for credentials, launches a headless browser, and fetches your full history (~30 min for 10 years). After that, daily syncs take seconds.
Connect AI
Add the MCP server to Claude Code, Claude Desktop, or any MCP client. The config depends on how you installed:
Claude Code (one-liner) — registers the server at user scope so it’s available in every project:
# pip / brew install
claude mcp add -s user garmin -- garmin-mcp
# git clone
claude mcp add -s user garmin \
-e GARMIN_DATA_DIR=/absolute/path/to/garmin-givemydata \
-- /absolute/path/to/garmin-givemydata/venv/bin/python \
/absolute/path/to/garmin-givemydata/run_mcp.py
Verify with claude mcp list. Skip the manual JSON below.
Homebrew or pip install — garmin-mcp is already in your PATH:
{
"mcpServers": {
"garmin": {
"command": "garmin-mcp"
}
}
}
Git clone — use absolute paths to the venv and set GARMIN_DATA_DIR so the MCP server finds your database:
{
"mcpServers": {
"garmin": {
"command": "/absolute/path/to/garmin-givemydata/venv/bin/python",
"args": ["/absolute/path/to/garmin-givemydata/run_mcp.py"],
"cwd": "/absolute/path/to/garmin-givemydata",
"env": {
"GARMIN_DATA_DIR": "/absolute/path/to/garmin-givemydata"
}
}
}
}
Note:
GARMIN_DATA_DIRtells the MCP server wheregarmin.dblives. Without it, the server falls back to~/.garmin-givemydata/which may not be where your data is if you cloned to a custom location.
Save this as:
- Claude Code:
.mcp.jsonin your project root, or~/.claude/settings.jsonundermcpServersfor global access - Claude Desktop:
~/Library/Application Support/Claude/claude_desktop_config.json(macOS) or%APPDATA%\Claude\claude_desktop_config.json(Windows)
Restart your client and run /mcp to approve the server. Then ask:
"How was my sleep this week?"
"Am I overtraining? Check my HRV and recovery"
"Compare my fitness this month vs last month"
"Give me a full sports medicine health check"
What You Get
- ALL your data in one command — 50 tables, activities with splits/weather/HR zones/GPS trackpoints, original FIT files
- 10+ years of history fetched automatically, smart incremental sync after that
- 45 MCP tools for AI analysis — not just raw data, but tools with clinical context, anomaly detection, and professional training metrics
- Export to anything — CSV, JSON, GPX, TCX from your local database
- Your data stays local — nothing is sent anywhere
MCP Tools (45)
The MCP server gives AI assistants deep access to your health data. Every tool returns data + context — not just numbers, but trend direction, anomaly flags, clinical thresholds, and goal attainment.
Usage
Fetch (from Garmin Connect)
garmin-givemydata # smart sync (all data + FIT files)
garmin-givemydata --full # force full historical re-fetch
garmin-givemydata --days 90 # fetch last 90 days
garmin-givemydata --since 2025-01-01 # fetch from specific date
garmin-givemydata --profile health # health metrics only
garmin-givemydata --profile activities # activities + FIT files only
garmin-givemydata --profile sleep # sleep data only
garmin-givemydata --no-files # skip FIT file downloads
garmin-givemydata # parses trackpoints for newly downloaded FIT files by default
garmin-givemydata --no-trackpoints # skip trackpoint parsing during sync
garmin-givemydata --rebuild-trackpoints # full rebuild: reparse all downloaded FIT files
garmin-givemydata --status # check database contents
FIT file download only
garmin-givemydata --fit-only --latest # latest FIT file
garmin-givemydata --fit-only --date 2026-03-30 # specific date
garmin-givemydata --fit-only --days 7 # last 7 days
garmin-givemydata --fit-only # all FIT files
Export (from local database)
garmin-givemydata --export ./output # CSV + JSON
garmin-givemydata --export-gpx ./gpx # GPX (for Strava, Komoot)
garmin-givemydata --export-tcx ./tcx # TCX (for TrainingPeaks)
Browser engine
Uses SeleniumBase UC mode (undetected Chrome) for Cloudflare bypass. Requires Google Chrome installed.
| Engine | Headless | Cloudflare bypass | Session lifetime |
|---|---|---|---|
| SeleniumBase UC (Chrome) | Yes (via Xvfb on Linux) | Yes | Weeks on stable IP |
Note: cf_clearance is bound to your IP address. If your IP changes, the session expires regardless of profile state. For unattended use, run on a machine with a stable egress IP.
Architecture
Platform Support
| Platform | Status | Notes |
|---|---|---|
| macOS | Tested | Primary development platform |
| Linux (Ubuntu/Debian/Fedora) | Supported | Needs Chrome + optional xvfb for headless SSH |
| Windows 10/11 | Supported | Use PowerShell or Command Prompt |
| WSL2 | Supported | Works headless with Xvfb |
Troubleshooting
Contributing
Support This Project
- Star this repository — helps others discover the project
- Report issues — improve stability and compatibility
- Spread the word — share with other Garmin users
- Contribute code — new endpoints, MCP tools, export formats, bug fixes
- File a GDPR/CCPA request with Garmin — the more users who formally request data portability, the harder it is to ignore
Acknowledgments
Disclaimer
This tool is unofficial and not affiliated with Garmin. It accesses Garmin Connect using your own credentials to retrieve your own data. Use may violate Garmin’s Terms of Service. You assume all risk and responsibility. See the full disclaimer for details.
License
AGPL-3.0 — Free to use, modify, and distribute. If you build a service using this code, you must keep it open source.
Install
This server does not publish a one-line install command.
Open the repository installation guideConfiguration
{
"mcpServers": {
"garmin": {
"command": "garmin-mcp"
}
}
}