HealthSave Get on App Store

To get a REST API over your Apple Health data, HealthSave Pro background-syncs your HealthKit data to a server you run, and that server exposes your metrics over HTTP as CSV or JSON, behind your own API key. There is no HealthSave cloud in the middle: your data goes from your iPhone to your hardware, and the API answers from your database.

Why Apple Health has no API (and what to do about it)

Apple Health is a vault, not a service. There is no official REST endpoint, no developer token, no GET /heart-rate you can curl. The only sanctioned way out is the Health app's Export All Health Data button, which produces a single enormous export.xml ZIP that is awkward to parse and impossible to automate. If you want your body data behind a queryable API, you have to build the pipe yourself.

HealthSave is that pipe. The app reads HealthKit on-device and, with Pro, pushes batches to a server URL you set. That server holds your history and answers HTTP queries against it. The key honesty up front: HealthSave does not host anything. "Custom REST API" means an API you stand up and own.

The architecture

iPhone (Apple Health)
   └─ HealthSave Pro  ──(background sync, ~1–5 min, POST /api/apple/batch)──▶  your server
                                                                               └─▶ REST read API
                                                                                   GET /api/v2/export
                                                                                   GET /api/v2/export/metrics
                                                                                   GET /api/v2/sync/runs/latest

The receiving server is the open-core HealthSave Observatory (a FastAPI + TimescaleDB stack you bring up with Docker), or anything you write yourself. The app speaks a frozen v1 contract so the wire format never shifts under you.

The endpoints

Every request carries an x-api-key header. List what you have, then pull a metric:

# What metrics do I have, and over what range?
curl -H "x-api-key: YOUR_KEY" \
  https://your-server.example/api/v2/export/metrics

# Last 30 days of resting heart rate as CSV
curl -H "x-api-key: YOUR_KEY" \
  "https://your-server.example/api/v2/export?metric=resting_heart_rate&format=csv&days=30"

# A date range of HRV as JSON
curl -H "x-api-key: YOUR_KEY" \
  "https://your-server.example/api/v2/export?metric=heart_rate_variability&format=json&from=2026-01-01&to=2026-06-01"

# Confirm the most recent sync actually landed
curl -H "x-api-key: YOUR_KEY" \
  https://your-server.example/api/v2/sync/runs/latest

Query parameters on /api/v2/export: metric (required), format (json default, or csv), from/to (ISO dates), days (a shortcut for "last N days"), and limit. A single call returns at most 100,000 rows, page longer histories with from/to. metric=all&format=json dumps everything in one JSON object (CSV is one metric at a time).

Build your own server

You don't have to use the Observatory. The protocol and SDK layers are Apache-2.0, so any backend that implements POST /api/apple/batch receives the same batches the app sends. The full API contract documents the batch payload, the optional X-HealthSave-* receipt headers, and the auth model. Implement the ingest endpoint in Go, Node, Python, or whatever you like, and the app will sync to it unchanged.

Free vs Pro

CapabilityTier
On-device dashboard, CSV/JSON file exportFree
Background sync to your serverPro
REST API access (read plane)Pro
Unlimited export historyPro

Pro is a one-time $24.99 with Family Sharing, no subscription. For a developer that's the whole sync-and-API layer unlocked once.

Honest limits

Related

FAQ

Does HealthSave host the API for me?

No. There is no hosted backend. The API runs on a server you run, a NUC, Mac mini, Synology, Raspberry Pi, or a Proxmox VM. Your Apple Health data goes from your iPhone to your hardware and nowhere else.

What endpoints are available?

The iOS app writes with POST /api/apple/batch (a frozen v1 contract). The Observatory read plane adds GET /api/v2/export (one metric as CSV or JSON), GET /api/v2/export/metrics (the catalog with row counts and date ranges), GET /api/v2/sync/runs/latest (the last sync receipt), and GET /api/apple/status. Every endpoint is gated by an x-api-key header.

Can I build my own server instead of the Observatory?

Yes. The protocol and client SDK layers are Apache-2.0 licensed precisely so any backend can speak the wire format. The Observatory is the reference implementation; the contract is the standard. The full spec is on the API page.

Is there a rate or size limit?

A single export call returns at most 100,000 rows. Page through longer ranges with the from, to, and limit query parameters. The read plane is owner-scoped to your single-user data.

Which metrics can I query?

All of them that you sync, heart rate, HRV, resting HR, sleep stages, steps, blood oxygen, respiratory rate, VO2 max, workouts, weight, Time in Daylight, medication dose events, and more. Call GET /api/v2/export/metrics for the live list with counts.

HealthSave is not a medical device. It is for informational purposes only and does not diagnose, treat, cure, or prevent any disease or condition. The accuracy of any health data depends on your wearable device and its sensors. Privacy claims of zero data collection apply to the iOS app; self-host sync sends your data to your own server.

Get HealthSave

Download free and try the on-device export first. When you want a private REST API over your body data, a one-time Pro purchase unlocks background sync and API access to a server you run.

Download HealthSave on the App Store


HealthSave: Export Health Data, on iPhoneGet on the App Store