← All routes
Route record / Steps

Step records → a deduplicated total

Android recommends aggregation for cumulative step data instead of simply adding raw records from several sources.

DocumentedChecked 2026-11-03Tested on Android 15 emulator

Why two step counters can disagree

We wrote two overlapping walks to Health Connect on a clean Android 15 emulator, then asked for the same 15 minutes in two ways. Reading the individual records gave 360 steps. Asking Health Connect for a combined total gave 240.

Synthetic records for 17 November 2026, all times UTC
SourceTime windowWritten stepsAggregate for this source alone
A · first priority11:00–11:10120120
B · second priority11:05–11:15240240

The walks overlap for five minutes. The measured combined result matches all 120 steps from A plus 120 from the non-overlapping half of B. A program that simply adds both raw records counts both sources during the overlap. This example explains how an app can display a different number even when both apps can see the same data.

Repeat the measurement

  1. Use a fresh Android 15 test emulator. Download the source bundle and set ANDROID_HOME, JAVA_HOME (JDK 17+) and ANDROID_SERIAL. Our build used SDK platform 36 and build-tools 36.0.0.
  2. Run bash fixture.sh YOUR_UTC_START using an unused interval within the last day. The script installs two small test apps and writes a synthetic walk from each.
  3. At the prompt, finish Health Connect onboarding and open Manage data → Data sources and priority → Activity. Put sourcea above sourceb. Press Enter to read the records and request STEPS_COUNT_TOTAL, both combined and filtered by app.

We ran this on 18 November 2026 with Android 15, API 35, Google APIs arm64-v8a, build AE3A.240806.043/12960925. On the first read the raw records were visible while the aggregate was still unavailable. After checking source priority, the same query returned 240. A missing aggregate is a distinct result from zero. These are synthetic records from two test apps. A watch or vendor app may write different intervals or use its own step counter.

Download the Java source, runner and measured output (ZIP) →

Find your next check

Choose the observation that best matches what you see.

I can see the steps in one app only

Open Health Connect → Data and access → Activity → Steps and inspect the entries. If the writer is missing, check its permission to write steps and its export setting. If it appears, check the reader’s permission and the time of its last refresh.

Both apps list the same sources but the totals differ

Compare one short interval first. Open Data sources and priority under Manage data, note which sender is first, and look for overlapping records. Ask whether the reader displays raw records or the platform aggregate.

The numbers disagree around midnight

Write down the day boundaries and time zones each app uses. Choose an interval well inside the same day, then compare again. A daily time-zone boundary can assign the same walk to a different day.

The documented path

Source records → aggregate query → display
Writer
Multiple permitted apps
Reader
A Health Connect reading app
Record contract
StepsRecord / COUNT_TOTAL

Field-level evidence

FieldMeaningUnit / shape
countStep count for a record's time interval.Count
dataOriginFilterAn optional query filter restricting which writing app contributes.App package

Where the evidence stops

  • Different origin filters or time boundaries can produce different totals.
  • An aggregate result is not a physical validation of a sensor's counting accuracy.
  • A zero display and an absent result should not be treated as interchangeable evidence.

What to check next

  1. Compare the same time interval and timezone.
  2. Check whether the destination adds raw records or requests an aggregate.
  3. Record any origin filter and source-priority behaviour before comparing totals.

Primary sources

  1. Android DevelopersRead raw data

    Foreground/background reads, history access, origin filtering and pagination. Page updated 9 October 2026.

    Source checked 2026-11-03
  2. Android DevelopersRead aggregated data

    Aggregation and data-origin filtering; consult current deduplication rules.

    Source checked 2026-11-03
  3. Record categories, permissions and mandatory fields.

    Source checked 2026-11-03