Install Groups

Control which Android builds can see updates for each other using install groups.

Install groups let you tag builds with one or more group names to control update visibility between builds. See the product documentation for a full explanation of how install groups work.

Pass --install-group one or more times:

Copied
sentry-cli build upload app.apk \
  --org your-org \
  --project your-project \
  --build-configuration Release \
  --install-group alpha \
  --install-group staging

Set installGroups in the distribution block:

build.gradle.kts
Copied
sentry {
  distribution {
    enabled = true
    installGroups.set(setOf("alpha", "staging"))
  }
}

Pass the install_groups parameter:

Fastfile
Copied
sentry_upload_build(
  org_slug: 'your-org',
  project_slug: 'your-project',
  apk_path: 'path/to/app.apk',
  build_configuration: 'Release',
  install_groups: ['alpha', 'staging']
)

When the Auto-Update SDK checks for updates, the server returns the single latest build (highest semver version, with build number as tiebreaker) whose install groups overlap with the filter:

  • If the SDK sends groups explicitly, the server uses those to filter.
  • If the SDK doesn't send groups, the server falls back to looking up the uploaded build by buildVersion and buildNumber and using that build's install groups. If multiple builds share the same version and build number, the server picks the most recently uploaded one, which may lead to unexpected results.

We recommend configuring the SDK to send install groups explicitly to ensure deterministic filtering.

The Gradle plugin's installGroups config handles this automatically:

  1. Upload: Passes --install-group flags to sentry-cli so the build is tagged on the server.
  2. Embed: Writes the groups to sentry-distribution.properties inside the APK (as io.sentry.distribution.install-groups-override). The Auto-Update SDK reads this value at runtime and sends the groups explicitly as query parameters.

If you need the SDK to filter by different groups than what the build was uploaded with (for example, based on a feature flag or user setting), you can override them via SentryOptions:

Copied
SentryAndroid.init(context) { options ->
    options.distribution.installGroups = setOf("beta", "internal")
}

This overrides the groups the SDK sends when checking for updates. It does not change the groups the build was tagged with on the server.

Was this helpful?
Help improve this content
Our documentation is open source and available on GitHub. Your contributions are welcome, whether fixing a typo (drat!) or suggesting an update ("yeah, this would be better").