# android/location-samples

Multiple samples showing the best practices in location APIs on Android.

Repository: https://github.com/android/location-samples
Canonical: https://ross.abutalabs.com/products/location-samples
Language: Kotlin
License: Apache-2.0
License Family: permissive
Archived: true
Last push: 2023-08-23T08:46:50+00:00

## Health v2 (maintenance only)
Score: 10/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 4342, "days_push": 1106, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases, archived
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2699, forks 2713 (observed 2026-08-28T04:07:11.342470+00:00)

## What it is
A collection of Android sample apps demonstrating Google Play Services location and context APIs, including geofencing, background location updates, activity recognition, and the Sleep API, written in Kotlin and Java. The repository is deprecated and no longer maintained, with samples moved to the android/platform-samples repo.

## Use cases
- learn how to get background location updates on android
- android geofencing example code
- detect user activity like walking or driving on android
- convert device location to address with geocoding on android
- sample code for android awareness api
- track user sleep activity with android sleep api

## When to choose
- you need reference code for Android location APIs and don't mind it being archived
- you're targeting older Android APIs and want proven sample patterns

## When to avoid
- you want actively maintained samples - use android/platform-samples instead
- you need production-ready code rather than educational examples

## Facets
- artifact type: learning-resource
- maturity: abandoned
- function: geospatial, sdk, developer-tools
- domain: mobile-development, android-tools, tutorials
- platform: jvm
- tags: location-apis, sample-code, google-play-services, geofencing, activity-recognition, deprecated, maps, android, mobile

## Member repositories
- android/location-samples (main) score 10

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:07:11.342470+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T02:16:07.279398+00:00, confidence not recorded.
  - readme: https://github.com/android/location-samples (fetched 2026-08-28T04:07:11.342470+00:00, sha 595ea5d6689f)
- Data as of 2026-08-30T08:39:29.467469+00:00.
