androidandroid-autofill-managerpassword-managerpassword-autofill

How to stop dialog save password to Google on Android 14?


Since Android 8 to 13, when you want to disable Password Manager's saving password we only need to include this:

android:importantForAutofill="no"

But it seems something changed in Android 14 and that autofield exclusion doesn't work.

I also tried to include

android:importantForAutofill="noExcludeDescendants"

on the parent's layout.

Also, I tried to remove android:inputType="textEmailAddress" and android:inputType="textPassword" in the TextInputEditText, but it also doesn't work.

This is the dialog that is shown in Android 14.

Google Password Manager save dialog


Solution

  • According to this issue in the Google Issue Tracker, this appears to be intended behavior:

    Status: Won't Fix (Intended Behavior) Thanks for submitting this feedback.

    This behavior is working as intended on Android 14, as we updated the behavior of “autofill importance”. In Android 14+, Views where Views#isImportantForAutofill is no or noExcludeDescendants will typically trigger autofill when focused and are always included in the FillRequest data, and autofill providers will be able to show suggestions when relevant.

    The Android Autofill team is constantly looking for ways to improve the user experience. With this change, we expect users will be able to use autofill more often when they need it. Additional details can be found in the documentation.

    So this is not a bug, Google just wants to "encourage" people to use this feature. Please check the answer from @Michael Winkler for a workaround.