Switching to a new phone is always exciting, but re-entering login details for all your apps? Not so much. It’s a hassle that frustrates users and, often, makes them abandon apps entirely. To solve this, Android is rolling out a new feature called Restore Credentials, part of its Credential Manager API.
This feature makes setting up apps on a new phone smooth and effortless. Users stay logged in, and apps re-engage them immediately—no need to remember or retype credentials. Here’s everything you need to know about how it works and why it’s a win for users and developers alike.
What is Restore Credentials?
Restore Credentials is a new tool that helps apps restore user accounts automatically when users move to a new device. It works during the setup process:
- Users restore their apps and data (from the cloud or locally).
- Apps fetch a special restore key saved on the old device and log the user in automatically.
No additional steps or credentials are required from the user. It’s as if they never left their old phone!

Why It’s Great for Users and Developers
- For Users:
- Hassle-Free Setup: Switch phones without worrying about logins.
- Instant Access: Notifications and account data are ready to go as soon as apps are restored.
- For Developers:
- No Extra Effort: Restore Credentials works with Android’s existing backup system.
- Seamless Integration: Uses the same server-side setup as passkeys (FIDO2 compatible).
- Better Retention: Reduce churn by keeping users connected effortlessly.
How Restore Credentials Works
On the Old Phone:
- The app creates a restore key when the user logs in. This key is stored locally and, if allowed, backed up to the cloud.
On the New Phone:
- During device setup, users can restore data via the cloud or locally.
- The restore key is transferred along with the app data.
- Once available, the app uses this key to log the user in automatically.
Apps using Android’s BackupAgent can even log users in silently, so they never need to touch a button.

How to Add Restore Credentials to Your App
Using the Jetpack Credential Manager makes adding this feature easy. Here’s the basic process:
- Create a Restore Credential: Generate a restore key when users log in to your app.
- Retrieve the Credential: When a user restores the app on a new device, fetch the restore key and log them in.
- Clear the Credential: If users log out, delete the restore key to avoid auto-logins.
Here’s how the code looks:
// Add Credential Manager dependency
implementation("androidx.credentials:credentials:1.5.0-beta01")// Create a Restore Credentialval createRequest = CreateRestoreCredentialRequest(registrationJson, true)
val response = CredentialManager.create(context).createCredential(context, createRequest)
// Retrieve the Restore Credential
val getRequest = GetCredentialRequest(listOf(GetRestoreCredentialOption(authenticationJson)))
val response = CredentialManager.create(context).getCredential(context, getRequest)
// Clear the Credential
val clearRequest = ClearCredentialStateRequest(1)
CredentialManager.create(context).clearCredentialState(clearRequest)
Why This Matters
Restore Credentials simplifies life for users and developers alike. Users can seamlessly switch devices without frustration, and developers can reduce app abandonment while ensuring secure, automatic logins.
Want to take your app’s user experience to the next level? Start exploring Restore Credentials with the Jetpack Credential Manager today.
It’s a small step for your app, but a giant leap for user satisfaction!



11 Responses
Alright, video poker fans! Videopokervn seems like a decent spot. Selection is alright, layouts clean. Just need to get some luck. Try your hand at video poker.
Alright mate bet123game is on my radar now. Heard some good things about their odds. Gonna give it a whirl this weekend and see if it’s worth the hype. Peep it here: bet123game
Coolbetmx seems pretty legit, dude. Good odds on sports, and the casino games are solid. Recommend hitting it up: coolbetmx
Slotbajilive? Live slots sound kinda fun. Wonder if you can chat with other players or something. Worth checking out I reckon! Find it here: slotbajilive
Hey folks, just tried baazilife99 and had a good time. The site’s easy to use and there’s a decent variety of games. Give it a shot, see what you think: baazilife99
When I initially commented I clicked the “Notify me when new comments are added” checkbox and now
each time a comment is added I get four emails with the same comment.
Is there any way you can remove people from that service? Appreciate it!
Can you be more specific about the content of your article? After reading it, I still have some doubts. Hope you can help me.
Thank you for your sharing. I am worried that I lack creative ideas. It is your article that makes me full of hope. Thank you. But, I have a question, can you help me? https://www.binance.bh/futures/ref?code=QCGZMHR6
Having read this I believed it was rather enlightening.
I appreciate you finding the time and energy to put this article together.
I once again find myself personally spending a lot of
time both reading and posting comments. But so what, it was still worthwhile!
When some one searches for his vital thing, so he/she wants to be available that in detail, thus that thing is maintained over
here.
Appreciating the commitment you put into your blog and in depth information you provide.
It’s awesome to come across a blog every once in a while that isn’t the
same outdated rehashed material. Fantastic read!
I’ve saved your site and I’m adding your RSS feeds
to my Google account.