Data types
Every HealthDataType with its default unit and its availability on Apple Health and Google Health Connect, plus the supported workout types.
Data types are defined in the HealthDataType enum, and each type has a default HealthDataUnit.
- iOS supports HealthKit-specific types such as workouts, ECG, sleep stages, nutrition, and many biometrics.
- Android supports Health Connect types including steps, heart rate, sleep, speed and distance, nutrition, hydration, menstruation flow, and more.
Platform type lists
The plugin exposes a list of the supported types for each platform, dataTypeKeysIOS and dataTypeKeysAndroid:
Use them for quick testing or to build permission requests. The lists are the same on every device, and dataTypeKeysIOS includes types that a device may not support:
TOTAL_CALORIES_BURNED, which the plugin does not support on iOS;- the types that need iOS 16.0 or later, marked in the table below.
On iOS, reading a type that the device does not support throws a PlatformException, and a read of several types then fails as a whole. To request access to all of dataTypeKeysIOS, ask for READ access only: WRITE access fails for the types that apps can only read. For ELECTROCARDIOGRAM, for example, requestAuthorization() throws an ArgumentError, and for EXERCISE_TIME, HealthKit throws an exception that crashes the app.
Health data types
All supported health data types, their units, and their platform availability. In the comments, iOS 16.0 or later marks a type that the plugin supports only from that version. On iOS 15, reading such a type throws a PlatformException, and writeHealthData() returns false.
| Data type | Unit | Apple Health | Google Health Connect | Comments |
|---|---|---|---|---|
ACTIVE_ENERGY_BURNED | KILOCALORIE | yes | yes | |
ATRIAL_FIBRILLATION_BURDEN | PERCENT | yes | iOS 16.0 or later, read-only | |
BASAL_ENERGY_BURNED | KILOCALORIE | yes | yes | On Android, Health Connect's basal metabolic rate in kilocalories per day |
BLOOD_GLUCOSE | MILLIGRAM_PER_DECILITER | yes | yes | |
BLOOD_OXYGEN | PERCENT | yes | yes | |
BLOOD_PRESSURE_DIASTOLIC | MILLIMETER_OF_MERCURY | yes | yes | |
BLOOD_PRESSURE_SYSTOLIC | MILLIMETER_OF_MERCURY | yes | yes | |
BODY_FAT_PERCENTAGE | PERCENT | yes | yes | |
BODY_MASS_INDEX | NO_UNIT | yes | yes | On Android, the plugin computes it from the latest HEIGHT and each WEIGHT in the time range, and writeHealthData() returns false for it. |
BODY_TEMPERATURE | DEGREE_CELSIUS | yes | yes | |
BODY_WATER_MASS | KILOGRAM | yes | ||
ELECTRODERMAL_ACTIVITY | SIEMEN | yes | ||
HEART_RATE | BEATS_PER_MINUTE | yes | yes | |
HEIGHT | METER | yes | yes | |
RESTING_HEART_RATE | BEATS_PER_MINUTE | yes | yes | |
RESPIRATORY_RATE | RESPIRATIONS_PER_MINUTE | yes | yes | |
FORCED_EXPIRATORY_VOLUME | LITER | yes | HealthKit's forcedExpiratoryVolume1 | |
PERIPHERAL_PERFUSION_INDEX | PERCENT | yes | ||
STEPS | COUNT | yes | yes | |
WAIST_CIRCUMFERENCE | METER | yes | ||
WALKING_HEART_RATE | BEATS_PER_MINUTE | yes | Read-only | |
WEIGHT | KILOGRAM | yes | yes | |
DISTANCE_WALKING_RUNNING | METER | yes | ||
DISTANCE_SWIMMING | METER | yes | ||
DISTANCE_CYCLING | METER | yes | ||
FLIGHTS_CLIMBED | COUNT | yes | yes | |
DISTANCE_DELTA | METER | yes | ||
MINDFULNESS | MINUTE | yes | ||
SLEEP_ASLEEP | MINUTE | yes | yes | On iOS, this refers to asleepUnspecified, and on Android this refers to STAGE_TYPE_SLEEPING (asleep but specific stage is unknown) |
SLEEP_AWAKE | MINUTE | yes | yes | |
SLEEP_AWAKE_IN_BED | MINUTE | yes | ||
SLEEP_DEEP | MINUTE | yes | yes | On iOS, this refers to asleepDeep, which HealthKit has from iOS 16.0. On iOS 15, reads return no data, and writeHealthData() saves it as SLEEP_ASLEEP. |
SLEEP_IN_BED | MINUTE | yes | ||
SLEEP_LIGHT | MINUTE | yes | yes | On iOS, this refers to asleepCore, which HealthKit has from iOS 16.0. On iOS 15, reads return no data, and writeHealthData() saves it as SLEEP_ASLEEP. |
SLEEP_OUT_OF_BED | MINUTE | yes | ||
SLEEP_REM | MINUTE | yes | yes | On iOS, this refers to asleepREM, which HealthKit has from iOS 16.0. On iOS 15, reads return no data, and writeHealthData() saves it as SLEEP_ASLEEP. |
SLEEP_UNKNOWN | MINUTE | yes | ||
SLEEP_SESSION | MINUTE | yes | ||
WATER | LITER | yes | yes | |
EXERCISE_TIME | MINUTE | yes | Read-only | |
WORKOUT | NO_UNIT | yes | yes | See workout types table below |
WORKOUT_ROUTE | NO_UNIT | yes | yes | The route of a workout. Write it with startWorkoutRoute(), insertWorkoutRouteData() and finishWorkoutRoute(). |
HIGH_HEART_RATE_EVENT | NO_UNIT | yes | Read-only, recorded by Apple Watch | |
LOW_HEART_RATE_EVENT | NO_UNIT | yes | Read-only, recorded by Apple Watch | |
IRREGULAR_HEART_RATE_EVENT | NO_UNIT | yes | Read-only, recorded by Apple Watch | |
HEART_RATE_VARIABILITY_RMSSD | MILLISECOND | yes | ||
HEART_RATE_VARIABILITY_SDNN | MILLISECOND | yes | Recorded by Apple Watch | |
HEADACHE_NOT_PRESENT | MINUTE | yes | ||
HEADACHE_MILD | MINUTE | yes | ||
HEADACHE_MODERATE | MINUTE | yes | ||
HEADACHE_SEVERE | MINUTE | yes | ||
HEADACHE_UNSPECIFIED | MINUTE | yes | ||
AUDIOGRAM | DECIBEL_HEARING_LEVEL | yes | ||
ELECTROCARDIOGRAM | VOLT | yes | Read-only, recorded by Apple Watch | |
NUTRITION | NO_UNIT | yes | yes | |
DIETARY_* | GRAM | yes | 38 nutrient types, such as DIETARY_PROTEIN_CONSUMED. DIETARY_ENERGY_CONSUMED uses KILOCALORIE. On Android, use NUTRITION. | |
INSULIN_DELIVERY | INTERNATIONAL_UNIT | yes | ||
MENSTRUATION_FLOW | NO_UNIT | yes | yes | |
WATER_TEMPERATURE | DEGREE_CELSIUS | yes | iOS 16.0 or later. Apple Watch Ultra records it during dives and swimming workouts. | |
SLEEP_WRIST_TEMPERATURE | DEGREE_CELSIUS | yes | iOS 16.0 or later, read-only | |
SKIN_TEMPERATURE | DEGREE_CELSIUS | yes | Only where isSkinTemperatureAvailable() returns true; elsewhere, reads and writeHealthData() throw a HealthException. The value is a SkinTemperatureHealthValue. | |
UNDERWATER_DEPTH | METER | yes | iOS 16.0 or later. Apple Watch Ultra records it during dives. | |
UV_INDEX | COUNT | yes | iOS 16.0 or later | |
LEAN_BODY_MASS | KILOGRAM | yes | yes | |
WALKING_SPEED | METER_PER_SECOND | yes | Not on Android: use SPEED, which has the same unit | |
SPEED | METER_PER_SECOND | yes | ||
TOTAL_CALORIES_BURNED | KILOCALORIE | yes | Also in dataTypeKeysIOS, but not supported on iOS: reads throw a PlatformException, and writeHealthData() returns false. On iOS, use ACTIVE_ENERGY_BURNED and BASAL_ENERGY_BURNED. | |
ACTIVITY_INTENSITY | MINUTE | yes | Depends on the Health Connect version on the device, which the plugin does not check; without support, reads return no data. Write it with writeActivityIntensity(). The value is an ActivityIntensityHealthValue. | |
APPLE_MOVE_TIME | SECOND | yes | READ Only | |
APPLE_STAND_HOUR | HOUR | yes | READ Only. The value is HealthKit's HKCategoryValueAppleStandHour: 0 (stood) or 1 (idle), not a number of hours. | |
APPLE_STAND_TIME | SECOND | yes | Read-only | |
BIRTH_DATE | NO_UNIT | yes | Read-only HealthKit characteristic: the birth date in seconds since 1970, or 0 when it is not available | |
GENDER | NO_UNIT | yes | Read-only HealthKit characteristic: the HKBiologicalSex raw value | |
BLOOD_TYPE | NO_UNIT | yes | Read-only HealthKit characteristic: the HKBloodType raw value |
Workout types
All workout activity types (HealthWorkoutActivityType) and their platform availability. Workouts are represented as HealthDataType.WORKOUT; see Workouts for the value they carry.
In the platform columns, (yes) marks a type that the plugin stores as another workout type on that platform; the comments give the details.
When several names share one platform type, a read returns one of them, whatever name the workout was written with. On Android, getHealthDataFromTypes() returns every dancing workout as CARDIO_DANCE. On iOS, a run can come back as RUNNING or RUNNING_TREADMILL, and the name can change between app launches.
| Workout type | Apple Health | Google Health Connect | Comments |
|---|---|---|---|
AMERICAN_FOOTBALL | yes | yes | |
ARCHERY | yes | ||
AUSTRALIAN_FOOTBALL | yes | yes | |
BADMINTON | yes | yes | |
BARRE | yes | ||
BASEBALL | yes | yes | |
BASKETBALL | yes | yes | |
BIKING | yes | yes | On iOS this is CYCLING, but name changed here to fit with Android |
BIKING_STATIONARY | Not on either platform: on Android, writeWorkoutData() returns false | ||
BOWLING | yes | ||
BOXING | yes | yes | |
CALISTHENICS | yes | ||
CARDIO_DANCE | yes | (yes) | On Android this will be stored as DANCING |
CLIMBING | yes | ||
COOLDOWN | yes | ||
CORE_TRAINING | yes | ||
CRICKET | yes | yes | |
CROSS_COUNTRY_SKIING | yes | (yes) | On Android this will be stored as SKIING |
CROSS_TRAINING | yes | ||
CURLING | yes | ||
DANCING | yes | Not on iOS: use CARDIO_DANCE or SOCIAL_DANCE | |
DISC_SPORTS | yes | ||
DOWNHILL_SKIING | yes | (yes) | On Android this will be stored as SKIING |
ELLIPTICAL | yes | yes | |
EQUESTRIAN_SPORTS | yes | ||
FENCING | yes | yes | |
FISHING | yes | ||
FITNESS_GAMING | yes | ||
FLEXIBILITY | yes | ||
FRISBEE_DISC | yes | ||
FUNCTIONAL_STRENGTH_TRAINING | yes | Not on Android: use STRENGTH_TRAINING | |
GOLF | yes | yes | |
GUIDED_BREATHING | yes | ||
GYMNASTICS | yes | yes | |
HAND_CYCLING | yes | ||
HANDBALL | yes | yes | |
HIGH_INTENSITY_INTERVAL_TRAINING | yes | yes | |
HIKING | yes | yes | |
HOCKEY | yes | ||
HUNTING | yes | ||
ICE_SKATING | yes | ||
JUMP_ROPE | yes | ||
KICKBOXING | yes | ||
LACROSSE | yes | ||
MARTIAL_ARTS | yes | yes | |
MIND_AND_BODY | yes | ||
MIXED_CARDIO | yes | ||
PADDLE_SPORTS | yes | ||
PARAGLIDING | yes | ||
PICKLEBALL | yes | ||
PILATES | yes | yes | |
PLAY | yes | ||
PREPARATION_AND_RECOVERY | yes | ||
RACQUETBALL | yes | yes | |
ROCK_CLIMBING | yes | Not on iOS: use CLIMBING | |
ROWING | yes | yes | |
ROWING_MACHINE | yes | ||
RUGBY | yes | yes | |
RUNNING | yes | yes | |
RUNNING_TREADMILL | yes | Not on iOS: use RUNNING | |
SAILING | yes | yes | |
SCUBA_DIVING | yes | ||
SKATING | yes | yes | On iOS this will be stored as SKATING_SPORTS |
SKIING | yes | Not on iOS: use CROSS_COUNTRY_SKIING or DOWNHILL_SKIING | |
SNOW_SPORTS | yes | ||
SNOWBOARDING | yes | yes | |
SNOWSHOEING | yes | ||
SOCCER | yes | ||
SOCIAL_DANCE | yes | (yes) | On Android this will be stored as DANCING |
SOFTBALL | yes | yes | |
SQUASH | yes | yes | |
STAIR_CLIMBING | yes | yes | |
STAIR_CLIMBING_MACHINE | yes | ||
STAIRS | yes | ||
STEP_TRAINING | yes | ||
STRENGTH_TRAINING | yes | Not on iOS: use FUNCTIONAL_STRENGTH_TRAINING or TRADITIONAL_STRENGTH_TRAINING | |
SURFING | yes | yes | On iOS this is SURFING_SPORTS, but name changed here to fit with Android |
SWIMMING | yes | Not on Android: use SWIMMING_OPEN_WATER or SWIMMING_POOL | |
SWIMMING_OPEN_WATER | (yes) | yes | On iOS this will be stored as SWIMMING |
SWIMMING_POOL | (yes) | yes | On iOS this will be stored as SWIMMING |
TABLE_TENNIS | yes | yes | |
TAI_CHI | yes | ||
TENNIS | yes | yes | |
TRACK_AND_FIELD | yes | ||
TRADITIONAL_STRENGTH_TRAINING | yes | Not on Android: use STRENGTH_TRAINING | |
UNDERWATER_DIVING | yes | iOS 17.0 or later: on earlier versions, writeWorkoutData() throws a PlatformException | |
VOLLEYBALL | yes | yes | |
WALKING | yes | yes | |
WALKING_TREADMILL | Not on either platform: on Android, writeWorkoutData() returns false | ||
WATER_FITNESS | yes | ||
WATER_POLO | yes | yes | |
WATER_SPORTS | yes | ||
WEIGHTLIFTING | yes | ||
WHEELCHAIR | yes | Not on iOS: use WHEELCHAIR_RUN_PACE or WHEELCHAIR_WALK_PACE | |
WHEELCHAIR_RUN_PACE | yes | (yes) | On Android this will be stored as WHEELCHAIR |
WHEELCHAIR_WALK_PACE | yes | (yes) | On Android this will be stored as WHEELCHAIR |
WRESTLING | yes | ||
YOGA | yes | yes | |
OTHER | yes | yes |
Units
Each type maps to a default unit through dataTypeToUnit, for example HEART_RATE → BEATS_PER_MINUTE and WEIGHT → KILOGRAM:
PERCENT values are numbers from 0 to 100 on Android, as in Health Connect, and fractions from 0 to 1 on iOS, as in HealthKit. In reads and writes, an oxygen saturation of 98% is 98 on Android and 0.98 on iOS.
When you read data with getHealthDataFromTypes(), you can request a preferred unit per type in preferredUnits:
- Android: the plugin converts only
WEIGHTtoPOUND,HEIGHTtoCENTIMETERorINCH,BODY_TEMPERATUREandSKIN_TEMPERATUREtoDEGREE_FAHRENHEITorKELVIN, andBLOOD_GLUCOSEtoMILLIMOLES_PER_LITER. For other units, the values stay in the default unit, but the data points report the requested unit. - iOS: HealthKit converts the values to any unit of the same kind, such as
POUNDforWEIGHT. The plugin does not supportCENTIMETERandMILLIMOLES_PER_LITERon iOS. When the time range holds data, these units and units of another kind make HealthKit throw an exception, which crashes the app.
Sleep and headache categories
For the categorical sleep and headache types and for MINDFULNESS, the value is the length of the interval from dateFrom to dateTo in minutes.
Workouts
A workout is a HealthDataType.WORKOUT data point with a WorkoutHealthValue, which may include:
workoutActivityTypetotalEnergyBurned(+ unit)totalDistance(+ unit)totalSteps(+ unit, Android only)
On Android, workoutSummary is null; on iOS, the data point also has a workoutSummary.
Special data
| Type | Handling |
|---|---|
ECG (ELECTROCARDIOGRAM) | Parses the voltage series, average heart rate, sampling frequency, and classification. |
Nutrition (NUTRITION) | Supports a wide set of macro- and micronutrients. |
Menstruation flow (MENSTRUATION_FLOW) | Normalizes platform-specific values. |
Full enums
The complete enums and mappings are defined in the plugin's 13.3.2 source on GitHub:
The generated enum reference is in the API reference on pub.dev.