问题 I just implemented a bottom navigation (AS's default - File -> New -> Activity -> Bottom Navigation Activity) Everything is fine except for a space on the top of the nav_host_fragment . Since it was generated in a ConstraintLayout, I tried to clean the constraints and set the top constraint with parent , setting margin to '0dp' and set height to match_constraint . I unsuccessfully deleted the constraints and tried over and over again. I used Clean Project . I changed to RelativeLayout and set