Skip to main content
MCP server CX Codex

health4ai — Claude Code MCP server: what it does, how to install

health4ai is a Claude Code MCP server that queries Apple Health data from a personal Supabase or Postgres database.

MIT ★ 12 updated 2026-11-17

Install into Claude Code · Platform CLI All methods and platforms ↓
claude mcp add health4ai -e DATABASE_URL=<DATABASE_URL> -e HEALTHKIT_USER_ID=<HEALTHKIT_USER_ID> -- uvx health4ai
Open on GitHub

What health4ai does

The server communicates over stdio to fetch health records synced from the iOS app into your database. Running the server requires Python 3.11 or newer, along with the DATABASE_URL connection string and a valid user UUID in HEALTHKIT_USER_ID. The service halts startup if the user ID is missing or formatted incorrectly, while calendar buckets rely on HEALTH4AI_TZ with a default of UTC.

You can install the package via pip install health4ai and invoke the server using the health4ai command inside your client configuration.

What it helps with

  • query Apple Health metrics from Supabase
  • fetch workout history via MCP
  • access health records in Claude Code

Example prompts for the agent

  • Show my step count for this week
  • Get my average heart rate from yesterday
  • Find my active calories burned last month

How to install health4ai

Platform CLI

claude mcp add health4ai -e DATABASE_URL=<DATABASE_URL> -e HEALTHKIT_USER_ID=<HEALTHKIT_USER_ID> -- uvx health4ai

Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from health4ai <command>

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 health4ai

How to install health4ai in Claude Code?

Run claude mcp add health4ai -e DATABASE_URL=<DATABASE_URL> -e HEALTHKIT_USER_ID=<HEALTHKIT_USER_ID> -- uvx health4ai.

What does health4ai do?

It acts as a local MCP server that bridges your AI coding assistant with personal Apple Health data stored in Postgres.

What is required to run health4ai?

You need Python 3.11+, a Supabase Postgres DATABASE_URL, and the HEALTHKIT_USER_ID user identifier.

Similar MCP servers

All MCP servers for Data and databases →

Project sponsors

Companies that keep this analytics open