git fsck --lost-found

Category: Git - Advanced

git fsck --lost-found

Find dangling commits and blobs not reachable from any ref

Finds objects that exist in the Git database but aren't reachable from any branch or tag — potentially recoverable commits.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.