iOS Health Data Export Application
A privacy-first React Native app for exporting Apple HealthKit data to portable formats, with scheduled API syncing and on-device-only processing.
Overview
A focused iOS utility that solves a specific problem: giving users ownership of their Apple Health data in portable, usable formats. The app reads over 100 health data types from HealthKit, processes them entirely on-device, and exports them as structured CSV or JSON files — ready for personal analysis, sharing with healthcare providers, or importing into other platforms.
No health data ever leaves the device unless the user explicitly triggers an export or configures their own API endpoint for automated syncing. The app has no backend, no cloud storage, and no server-side data processing.
Health Data Coverage
The app reads from 14 HealthKit categories spanning over 100 individual data types:
- Activity — steps, distances, flights climbed, active energy, exercise minutes, VO2 Max
- Heart — heart rate, HRV, resting heart rate, blood pressure, blood oxygen, AFib burden
- Body Measurements — weight, height, BMI, body fat percentage, lean body mass
- Mobility — walking speed, step length, asymmetry, stair speed, walking steadiness
- Sleep — sleep analysis, wrist temperature, breathing disturbances
- Nutrition — 27 types including macronutrients, vitamins, minerals, caffeine, and water
- Respiratory, Vitals, Hearing, Mindfulness, Symptoms, Running, Cycling — full HealthKit coverage
The app probes HealthKit on launch to detect which data types have recent records on the current device, showing users only the categories that contain data.
Export Pipeline
Users choose between two export modes:
- Summary — daily aggregates with sum, average, min, and max for each day, ideal for trend analysis over long periods
- Detailed — every individual sample recorded by HealthKit, providing granular data points with timestamps
The export process queries HealthKit in monthly chunks to manage memory pressure, caps individual data types at 100,000 records, and packages the output into a single ZIP file containing one CSV or JSON file per selected category plus a metadata manifest. Progress is shown in real time as the pipeline moves through querying, writing, compressing, and completion stages.
The finished ZIP is delivered through the native iOS share sheet — email, Files app, AirDrop, or any other sharing target.
Automated API Sync
A premium feature allows users to configure a custom HTTPS endpoint that receives health data on a schedule. The sync system supports five authentication methods — Bearer token, API key with custom header, Basic Auth, custom headers, or no authentication — with credentials stored in the iOS Keychain via Expo Secure Store.
Syncs run via iOS Background App Refresh, either hourly or daily, and only transmit data recorded since the last successful sync. Each sync attempt is logged with timestamp, record count, HTTP status, and any error details. Users can review sync history, test their endpoint connection, trigger manual syncs, and pause syncing without losing configuration.
Network preference controls ensure syncs only run on WiFi, cellular, or either, depending on user preference.
Monetisation
RevenueCat manages a freemium model with three purchase options — monthly subscription, annual subscription, and lifetime one-time purchase. The free tier provides the health data overview and category browsing. Premium unlocks all export functionality and API sync configuration.
Technical Architecture
- Navigation — Expo Router with a five-tab layout: Home (data overview), Export, API Sync, Subscription, and Settings
- State management — React Context providers for health data availability, subscription state, API sync configuration, and app refresh triggers
- HealthKit access —
@kingstinct/react-native-healthkitfor reading quantity and category samples, with anchored queries for incremental data fetching - File handling —
expo-file-systemfor write operations,fflatefor ZIP compression at level 6,expo-sharingfor the native share dialog - Styling — NativeWind (Tailwind CSS for React Native) providing a consistent design language across all screens
- Background processing —
expo-background-fetchandexpo-task-managerfor scheduled sync tasks, with@react-native-community/netinfofor connectivity checks - Security — authentication credentials in Expo Secure Store, health data never written to app storage or transmitted to first-party servers