You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add an option to disable the persistent installation ID #2309
Since 0.14.1 (#1661), sentry_init always creates <database_path>/installation_id and uses its value as event.user.id and the session did whenever no user ID is set. There is no option, API, or build flag to turn this off, so teams with privacy review requirements can't adopt 0.14.1+ without a review, because a persistent identifier is now generated and sent by default.
Current behavior (0.17.6)
sentry_init always calls sentry__run_load_installation_id (sentry_core.c#L221), which reads or creates the file (sentry_database.c#L177-L250). require_user_consent and send_default_pii don't change this.
Hooks don't fully cover it. on_crash always runs before the scope is applied, and with the crashpad and native backends before_send does too (crashpad, native), so the ID can't be removed there. Sessions have no hook.
Set an explicit empty user.id with sentry_options_set_initial_scope (0.16.8+, #2087). This puts it on the scope before the backend starts and before the first session update, which is sent during init since 0.17.5 (#2242). The installation_id file is still written to disk.
An option such as sentry_options_set_installation_id(options, 0) (naming up to the maintainers) that skips both creating the file and filling in user.id / did.
Related
The Native Data Collected docs page doesn't mention the installation ID.
Activity
linear-code commentedon Nov 13, 2026
NATIVE-243
feat: configurable installation ID