Why a door may not latch even when the lock still turns

https://publishoryx.com/s/qy1Hs1NshkNIvUQF9axKK

A door may fail to latch even when the lock turns because the strike plate is misaligned. Over time, settling of the house or swelling from humidity can shift the door or frame, so the latch misses the hole. The lock mechanism works, but the bolt does not fully engage. A trick is to check the gap between door and jamb when closed; if the door rubs or the bolt scrapes the plate, adjusting the plate position with a file or screwdriver may help.