Skip to main content

Health Connect

Health Connect is the Android store for health and fitness data. Apps such as Samsung Health can write data into it, and other apps can read it with the user's permission. D4L Collect reads Health Connect on the participant's phone. This is how D4L Collect gets sleep stages, SpO2, exercise sessions, speed, power, and VO2 max from the Samsung Galaxy Watch.

Health Connect works only on Android phones. The data on this page complements the data that the watch records directly. See Samsung Galaxy Watch.

Use Health Connect for Samsung Health data

Use Health Connect mainly to access data from Samsung Health. For other devices, such as the Pixel Watch, Garmin, or Oura, use the vendor-specific recordings.

At a glance​

TopicDetails
Source typeOn-device store (Android Health Connect), read by the study app on the phone
DevicesSamsung Galaxy Watch 5, 6, 7, and 8 with Samsung Health, paired with an Android phone
In Research StudioUnder Background recordings, select Health Connect
What participants doTrack sleep, SpO2, and workouts in Samsung Health, and allow the study app to read this data in Health Connect
Data rangeFrom the moment participants give their study consent. Data recorded before that is never collected.
CollectionThe study app reads new data from Health Connect periodically in the background.
ExportCSV, one file per signal and day. See Exported files.

Available signals​

SignalUnitSampling typeWhen it's measured
Sleepstage + sInterval one row per sleep stageSleep sessions
SpO2%Sample once per nightNight
Exercise sessiontype + sInterval one row per sessionWorkouts
Speedm/sSampleWorkouts
PowerWSampleWorkouts
VO2 maxml/min/kgSample per measurementWhen Samsung Health measures it

For the data types that Health Connect supports, see Android's list of data types.

Signal reference​

The tables show example rows from the CSV files.

Sleep​

Sleep stages of each sleep session. There's one row per stage: timestamp is the start of the stage and duration_s is its length in seconds. For the values, see Sleep stages. To get the sleep duration, add up the duration_s of all stages except unknown, awake, awakeInBed, and awakeOutOfBed for each sleep session.

File: Android Health Connect_sleep_sleepStage_duration_dataSource.csv

timestampsleepStageduration_sdataSource
2026-09-14T23:20:00ZsleepingLight2700samsung-health
2026-09-15T00:05:00ZsleepingDeep1500samsung-health
2026-09-15T00:30:00ZsleepingRem1200samsung-health

SpO2​

Blood oxygen saturation in percent, one value per night.

File: Android Health Connect_spo2_spo2_dataSource.csv

timestampspo2_%dataSource
2026-09-15T03:12:00Z96samsung-health

Exercise session​

One row per workout session. A workout can appear as more than one session, for example when the participant pauses and resumes. timestamp is the start of the workout, exerciseType is the type of workout, and duration_s is its length in seconds. For the codes, see Exercise type.

File: Android Health Connect_exercise_exerciseType_duration_dataSource.csv

timestampexerciseTypeduration_sdataSource
2026-10-19T07:38:55.226Z56749samsung-health
2026-10-19T07:53:19.570Z5648samsung-health

Speed​

Speed in meters per second, as samples during a workout. Samples come about once per second. Rows with 0 are standstill, for example when the participant paused. Longer gaps between timestamps mean no samples were recorded, for example during a pause.

File: Android Health Connect_speed_speed_dataSource.csv

timestampspeed_m/sdataSource
2026-10-19T07:39:03.401Z0samsung-health
2026-10-19T07:39:04.405Z1.0677217samsung-health
2026-10-19T07:39:05.409Z1.0677217samsung-health

Power​

Power in watts, as samples during a workout. Power data is available only if the participant records power during a workout, for example on a rowing machine or while cycling on a power meter or spin bike. Without a device that measures power, there are no power rows.

File: Android Health Connect_power_power_dataSource.csv

timestamppower_WdataSource
2026-09-15T12:30:05Z185samsung-health
2026-09-15T12:30:10Z192samsung-health

VO2 max​

VO2 max in ml/min/kg, one row per measurement, with the measurement method. For the codes, see VO2 max measurement method.

File: Android Health Connect_vo2max_vo2max_vo2maxMeasurementMethod_dataSource.csv

timestampvo2max_ml/min/kgvo2maxMeasurementMethoddataSource
2026-09-15T08:30:00Z41.30samsung-health

Exported files​

You find Health Connect data in the CSV export of your study data. For details, see Downloading study data.

{Subject ID}/csv/Recordings_Signal_Data/{YYYY-MM-DD}/Android Health Connect_{signal}_{columns}.csv
  • Each folder holds the data of one day. The folder name is the UTC date of the last value of that day, so it can differ by one day from the participant's local date.
  • Each signal has its own file. The file name starts with Android Health Connect_, followed by the signal and its value columns.
  • All files start with a timestamp column (UTC, ISO 8601, in milliseconds) and end with a dataSource column.

Know before you analyze​

Participants must allow access​

Participants choose which data the study app may read. For SpO2, they must also allow oxygen saturation in Samsung Health. Without permission, no rows are recorded, so a missing night can mean "no permission" as well as "no measurement".

One row per data source​

Health Connect can hold data from several apps, and D4L Collect keeps them apart. If two apps record the same measurement, you get one row per source, often with the same timestamp. The dataSource column tells you which source a row came from.

Filter by data source

For data from the Samsung Galaxy Watch, keep only rows if dataSource is samsung-health. If you analyze all rows, you can count the same workout or measurement twice.

Values in the dataSource column:

ValueMeaningWhen you see it
samsung-healthSamsung Health appData from the Samsung Galaxy Watch. This is the value you expect for all signals on this page.
google-fitGoogle Fit appThe participant also uses Google Fit, for example to track workouts.
internal-sensorThe phone itselfThe phone recorded the data without a watch, for example a workout tracked by the phone's sensors.
unknownAny other sourceAnother app writes to Health Connect, or the app doesn't say where the data came from. This includes data that a Pixel Watch or Fitbit writes through its own app.

Sleep is the exception: D4L Collect exports sleep stages from Samsung Health only, so they are always samsung-health.

Sleep-based signals need a worn watch​

Sleep stages and SpO2 exist only for nights when the participant wore the watch and Samsung Health tracked their sleep. Expect gaps on other nights.

Workout signals exist only during workouts​

Exercise sessions, speed, and power exist only when the participant started a workout in Samsung Health. Speed and power need a workout type that measures them, for example running or cycling. Outside workouts, there are no rows. Use the exercise session's start time and duration_s to find the speed and power samples that belong to it.

VO2 max depends on Samsung Health​

Samsung Health decides when it measures VO2 max, so there's no regular sampling interval. Don't expect a value every day.

Data from sources other than Health Connect​

Health Connect can read data from sources like Google Health, but these sources don't write all their data to it. For example, Google Health doesn't write SpO2. This is why you should use Health Connect mainly for Samsung Health data. For other devices, use the vendor-specific recordings. For the Pixel Watch, see Google Health and Google Pixel Watch.

Coded values​

Some columns use fixed values instead of free text or measurements.

Sleep stages​

The sleepStage column is exported as text. These are all possible values:

  • unknown
  • awake
  • awakeInBed
  • awakeOutOfBed
  • sleeping (no stage specified)
  • sleepingLight
  • sleepingDeep
  • sleepingRem

Exercise type​

The exerciseType column is exported as a number. It's the EXERCISE_TYPE_* constant of Android's ExerciseSessionRecord, for example 56 for running. Look up the other codes in that list.

VO2 max measurement method​

The vo2maxMeasurementMethod column is exported as a number. It's the MEASUREMENT_METHOD_* constant of Android's Vo2MaxRecord:

CodeMethod
0Other
1Metabolic cart
2Heart rate ratio
3Cooper test
4Multistage fitness test
5Rockport fitness test