---
title: "Uninstalling the app"
section: "frontend/analytics"
platforms: ["android", "swift"]
gen: 2
last-updated: "2026-03-25T17:40:00.000Z"
url: "https://docs.amplify.aws/react/frontend/analytics/app-uninstall/"
---

<!-- Platform: android -->
Some Amplify categories such as Analytics and Auth persist data to the local device. This application data is removed when a user uninstalls the application from the device.

If the [Android Auto Backup for Apps](https://developer.android.com/guide/topics/data/autobackup) service is enabled, this service will attempt to restore application data.

Amplify Auth uses [EncryptedSharedPreferences](https://developer.android.com/reference/androidx/security/crypto/EncryptedSharedPreferences) when persisting auth data. When an application is uninstalled, the [Android Keystore](https://developer.android.com/training/articles/keystore) keys used to create our EncryptedSharedPreferences files are deleted. Upon an application reinstall, these restored files are no longer readable due to the key removal from the Android Keystore.

Due to this limitation with EncryptedSharedPreferences, Auth information can’t be restored on an application reinstall. The user will have to re-authenticate.
<!-- /Platform -->

<!-- Platform: swift -->
Some Amplify categories such as Analytics, Auth, and DataStore persist data to the local device. Some of that data is automatically removed when a user uninstalls the app from the device.

Amplify stores Auth information in the local [system keychain](https://developer.apple.com/documentation/security/keychain_services), which does not guarantee any particular behavior around whether data is removed when an app is uninstalled.

Deciding on when to clear this auth information is not something that the SDK can do in a generic way, so App developers should decide when to clear the data by signing out. One strategy for accomplishing this would be to use [UserDefaults](https://developer.apple.com/documentation/foundation/userdefaults) to detect whether or not the app is launching for the first time, and invoking [`Auth.signOut()`](/[platform]/frontend/auth/sign-out/) if the app has not been launched before.
<!-- /Platform -->
