mcpField
H
health4ai

health4ai

Local
health4.aiHealth5Updated 1d ago

About health4ai

health4ai is a local MCP server for querying Apple Health data stored in a Supabase/Postgres project the user owns. Data is supplied by the health4ai iOS app, and the server is intended for stdio MCP clients.

Key features

  1. 01Query Apple Health data
  2. 02Connect to owned Supabase/Postgres
  3. 03Serve over stdio

Use cases

  1. 01Review personal Apple Health records
  2. 02Query health data from an MCP client

MCP support

It exposes a local stdio MCP server that lets compatible MCP clients query a selected user's Apple Health data in Supabase/Postgres.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

mcp.json · Universal config
{
"mcpServers": {
"jefflitt1-health4ai": {
"command": "uvx",
"args": [
"health4ai"
],
"env": {
"DATABASE_URL": "<DATABASE_URL>",
"HEALTHKIT_USER_ID": "<HEALTHKIT_USER_ID>"
}
}
}
}
Run commanduvx health4ai
Environment variables to set
DATABASE_URLSecretPostgres connection string for your Supabase project (transaction pooler; database password, not a service-role key).
HEALTHKIT_USER_IDUUID of the Supabase Auth user whose HealthKit data to query.

Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.

Packages
pypihealth4ai0.1.0

Tools

No tool list yet

Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.

Details

From the project README

health4ai MCP server

Local MCP server that queries your Apple Health data from a Supabase/Postgres project you own. Use it with Claude Desktop, Claude Code, Cursor, or any stdio MCP client.

The data gets there from the free health4ai iOS app: download it on the App Store. Setup guide: https://health4.ai/setup/

Install

pip install health4ai

Requires Python 3.11+. From a clone of the repo you can still run the previous path:

pip install -r mcp-server/requirements.txt
python mcp-server/main.py

Configure

The server talks to your database over stdio. Set these environment variables (or a .env file in the working directory):

VariableRequiredSecretDescription
DATABASE_URLyesyesPostgres connection string for your Supabase project (transaction pooler; database password, not the service_role key). SUPABASE_DB_URL is accepted as an alias.
HEALTHKIT_USER_IDyesnoUUID of the Supabase Auth user whose HealthKit rows to query. The server refuses to start if this is unset, not a UUID, or the 00000000-… placeholder.
HEALTH4AI_TZnonoIANA time zone for calendar-day buckets (default UTC).

Full walkthrough: docs/SETUP.md.

Run

After pip install health4ai:

health4ai
# or
python -m health4ai

Claude Desktop / Claude Code / Cursor (mcp.json):

{
  "mcpServers": {
    "health4ai": {
      "command": "health4ai",
      "env": {
        "DATABASE_URL": "postgresql://...",
        "HEALTHKIT_USER_ID": "<your auth user UID>"
      }
    }
  }
}

From a git clone, "command": "python" and "args": ["/path/to/health4ai/mcp-server/main.py"] still work.

License

MIT. See the repository LICENSE.

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.