🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

health-analyzer-mcp

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

health-analyzer-mcp

Apple Health data for AI agents — expose your Apple Health / HealthKit data to Claude, Cursor, and other MCP clients via the Health Data AI Analyzer Mac app. All data stays local.

latest
Source
npmnpm
Version
1.1.2
Version published
Maintainers
1
Created
Source

Apple Health MCP Server

Apple Health data for AI agents: an MCP server that gives Claude, Cursor, OpenClaw, and any other MCP client read-only access to your Apple Health / HealthKit data through the Health Data AI Analyzer Mac app. All data stays local on your Mac.

Why this server

The numbers this server returns match the Apple Health app. Health data exported from HealthKit is messy: the same step count or heart-rate sample is often recorded by both your iPhone and your Apple Watch, and different sources report in different units. The Health Data AI Analyzer Mac app (1.996+) de-duplicates overlapping samples across your iPhone and Apple Watch and unit-corrects every metric, so a question like "how many steps did I take last week?" returns the same figure you'd see in Apple Health — not an inflated double-count.

Requirements

  • Health Data AI Analyzer app (macOS)
  • Node.js 18+
  • An MCP client (OpenClaw, Claude Desktop, etc.)

Installation

npm install -g health-analyzer-mcp

Or install from source:

cd mcp-server
npm install
npm link

Configuration

Add to your MCP client config (e.g., OpenClaw or Claude Desktop):

{
  "mcpServers": {
    "health-analyzer": {
      "command": "health-analyzer-mcp"
    }
  }
}

For OpenClaw workspace skills, you can also keep the skill folder from this repo in your workspace:

skills/health-analyzer-mac-local/

That skill assumes this MCP server is installed and available as health-analyzer-mcp.

Usage

  • Open Health Data AI Analyzer and load your health data
  • Start your MCP client
  • Ask questions like:
    • "Give me my daily health brief"
    • "How many steps did I take last week?"
    • "What's my average sleep duration?"
    • "Show me my heart rate trends"
    • "How many workouts did I do this month?"

The MCP server reads the local API token automatically from:

~/Library/Application Support/Health Data AI Analyzer/local-api-token.txt

For the sandboxed App Store build, it will also search the container path automatically, for example:

~/Library/Containers/com.rumjahn.healthkitanalyzer/Data/Library/Application Support/Health Data AI Analyzer/local-api-token.txt

You can override it with:

HEALTH_ANALYZER_TOKEN=...
HEALTH_ANALYZER_TOKEN_FILE=/absolute/path/to/local-api-token.txt

Available Tools

ToolDescription
get_statusCheck whether the local API is running and a dataset is loaded
list_metricsCheck what health data is loaded
get_health_summaryOverview of all metrics
get_daily_health_briefDaily overview with sleep, steps, workouts, and recovery context
get_stepsStep counts and averages
get_sleepSleep duration and stages
get_heart_rateHeart rate, resting HR, and HRV trends
get_hrvHeart rate variability
get_weightWeight measurements
get_workoutsWorkout history
get_vo2maxVO2 max fitness level

Troubleshooting

"Cannot connect to Health Data AI Analyzer"

  • Make sure the Mac app is running
  • Make sure you have health data loaded in the app
  • Open the Mac app Settings and confirm the Local API section shows Running
  • If needed, set HEALTH_ANALYZER_TOKEN_FILE to the token file path shown in app Settings

Tools not showing up

  • Restart your MCP client after adding the config
  • Check that health-analyzer-mcp is in your PATH

Keywords

apple-health

FAQs

Package last updated on 01 Aug 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts