How do we disable the Keyguard to appear on the device after the boot up on Android 11 onwards. Also how should I remove the Status bar and navigation bar to appear from the device always.

I do not want to add any Full screen flags through my applications. I want the screen to be in kiosk mode always.

Are there any flags or properties in AOSP Frameworks or device make-file which we can override to achieve this.

1 Answer 1


You can hide navbar and status bar by setting the height of these dimens to 0dp.

  • status_bar_height_portrait
  • navigation_bar_height
  • navigation_bar_height_landscape
  • navigation_bar_width

For disabling the keyguard by default, you can set the following bool in Settings Provider to true

  • def_lockscreen_disabled
  • Hello. How to set these dimensions that you mentioned above? I'm asking the procedure that is to be followed.
    – Firelord
    Jun 15, 2023 at 12:30
  • You have to edit these in frameworks_base overlays or define your own TARGET_PRODUCT_OVERLAYS. Jun 15, 2023 at 13:47

You must log in to answer this question.

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