withingsmcp — Claude Code MCP server: what it does, how to install
Local-first MCP server supplying Withings body metrics, sleep phases, workouts, and heart stats to AI coding assistants without external token relays.
claude mcp add --env WITHINGS_CLIENT_ID=<WITHINGS_CLIENT_ID> --env WITHINGS_CLIENT_SECRET=<WITHINGS_CLIENT_SECRET> --env WITHINGS_REDIRECT_URI=<WITHINGS_REDIRECT_URI> --env WITHINGS_TOKEN_PATH=<WITHINGS_TOKEN_PATH> --env WITHINGS_PRIVACY_MODE=<WITHINGS_PRIVACY_MODE> --transport stdio withingsmcp -- npx -y withings-mcp-unofficialWhat withingsmcp does
This server connects AI models directly to the official Withings Public API while keeping credentials strictly on your machine. It handles signed OAuth tokens on localhost, operating over standard I/O by default or a sessionless local loopback HTTP server at http://127.0.0.1:3000.
You need an active developer app in the Withings partner portal configured with the redirect URL http://127.0.0.1:3000/callback. Without those credentials, the npx -y withings-mcp-unofficial setup command cannot obtain access. OAuth authorization codes expire within minutes, so finish the browser approval and token exchange promptly.
Through tools like withings_daily_summary and withings_weekly_summary, assistants inspect body composition, activity levels, and sleep patterns. Live sensor streaming remains unsupported by the upstream public API, limiting reads to recorded entries.
What it helps with
- feed body weight and body fat trends into assistant memory
- review sleep stages and efficiency records across specific dates
- retrieve daily step counts, calorie burn, and workout metrics
- inspect resting heart rates and recorded ECG logs
Example prompts for the agent
- Check connection with withings_connection_status and summarize my activity today using withings_daily_summary.
- Pull withings_weekly_summary as JSON and highlight any sleep deficit patterns.
- Run withings_body_sleep_investigation for entries after 2026-04-01 to see body composition changes.
How to install withingsmcp
Platform CLI
claude mcp add --env WITHINGS_CLIENT_ID=<WITHINGS_CLIENT_ID> --env WITHINGS_CLIENT_SECRET=<WITHINGS_CLIENT_SECRET> --env WITHINGS_REDIRECT_URI=<WITHINGS_REDIRECT_URI> --env WITHINGS_TOKEN_PATH=<WITHINGS_TOKEN_PATH> --env WITHINGS_PRIVACY_MODE=<WITHINGS_PRIVACY_MODE> --transport stdio withingsmcp -- npx -y withings-mcp-unofficialReplace <…> with your own values. 3 more environment variables are in the server README
Platform CLI
codex mcp add withingsmcp --env WITHINGS_CLIENT_ID=<WITHINGS_CLIENT_ID> --env WITHINGS_CLIENT_SECRET=<WITHINGS_CLIENT_SECRET> --env WITHINGS_REDIRECT_URI=<WITHINGS_REDIRECT_URI> --env WITHINGS_TOKEN_PATH=<WITHINGS_TOKEN_PATH> --env WITHINGS_PRIVACY_MODE=<WITHINGS_PRIVACY_MODE> -- npx -y withings-mcp-unofficialReplace <…> with your own values. 3 more environment variables are in the server README
Config file
{
"mcpServers": {
"withingsmcp": {
"command": "npx",
"args": [
"-y",
"withings-mcp-unofficial"
],
"env": {
"WITHINGS_CLIENT_ID": "<WITHINGS_CLIENT_ID>",
"WITHINGS_CLIENT_SECRET": "<WITHINGS_CLIENT_SECRET>",
"WITHINGS_REDIRECT_URI": "<WITHINGS_REDIRECT_URI>",
"WITHINGS_TOKEN_PATH": "<WITHINGS_TOKEN_PATH>",
"WITHINGS_PRIVACY_MODE": "<WITHINGS_PRIVACY_MODE>"
}
}
}
}Replace <…> with your own values. 3 more environment variables are in the server README
Config file
{
"servers": {
"withingsmcp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"withings-mcp-unofficial"
],
"env": {
"WITHINGS_CLIENT_ID": "<WITHINGS_CLIENT_ID>",
"WITHINGS_CLIENT_SECRET": "<WITHINGS_CLIENT_SECRET>",
"WITHINGS_REDIRECT_URI": "<WITHINGS_REDIRECT_URI>",
"WITHINGS_TOKEN_PATH": "<WITHINGS_TOKEN_PATH>",
"WITHINGS_PRIVACY_MODE": "<WITHINGS_PRIVACY_MODE>"
}
}
}
}Replace <…> with your own values. 3 more environment variables are in the server README
Platform CLI
gemini mcp add -e WITHINGS_CLIENT_ID=<WITHINGS_CLIENT_ID> -e WITHINGS_CLIENT_SECRET=<WITHINGS_CLIENT_SECRET> -e WITHINGS_REDIRECT_URI=<WITHINGS_REDIRECT_URI> -e WITHINGS_TOKEN_PATH=<WITHINGS_TOKEN_PATH> -e WITHINGS_PRIVACY_MODE=<WITHINGS_PRIVACY_MODE> withingsmcp npx -y withings-mcp-unofficialReplace <…> with your own values. 3 more environment variables are in the server README
Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about withingsmcp
How to install withingsmcp in Claude Code?
Run claude mcp add withingsmcp -e WITHINGS_CLIENT_SECRET=<WITHINGS_CLIENT_SECRET> -- npx -y withings-mcp-unofficial. Run npx -y withings-mcp-unofficial setup first to complete authentication.
What does withingsmcp do?
It bridges Withings health hardware records to AI agents using the Model Context Protocol while retaining OAuth tokens on your local drive.
Which OAuth scopes are necessary?
The server relies on user.activity for steps, workouts, and sleep, along with user.metrics for body composition and heart measurements.