If I perform below steps,

  1. I root Android phone,
  2. From third party apps available on Play Store, I change 16 digit Android device id(Let say from aaaaaaaaaaaaaaaaa to bbbbbbbbbbbbbbbb)
  3. And then again unroot the phonne.

Will unrooting the phone also change Android device id again or it will remain bbbbbbbbbbbbbbbb only?

Thanks in advance.

2 Answers 2


Unrooting your phone doesn't reverse the changes you made to /system. These changes are reversed only when you flash a stock / custom ROM. Of course, apps that you had installed earlier which had root privileges will not work

To sum up, your changed ID will remain till the next factory reset


First of all, tweaking that 16 digit Android ID doesn't require root access. You can change that ID using ADB alone. Since Android 5.0, this should work just fine.

adb shell settings get secure android_id                   # returns the current Android ID
adb shell settings put secure android_id YOUR-16-DIGIT-ID  # to change the ID with your new 16 digit ID

The Android ID is stored inside data partition. It is set on first boot after factory reset and remains until you factory reset again. It has got nothing to do with rooting and unrooting your device. So, if you changed that ID using some app and unrooted your phone later, that ID would persist until factory reset.

Note: since Android 8.0 each app sees android_id which is unique to that app. It is not the same android_id that you would see from settings command. See relevant documentation for more info on this.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .