I'm running iOS 26.5 on an iPhone 14 Pro and am currently stuck in a three-hour security lockout. I may have only one or two passcode attempts left, but I'm not sure how many remain. I somehow forgot a passcode I've used for years and don't want to risk permanently losing my photos, which are the main data I care about. Most of my other information is backed up to iCloud, and I recently upgraded my storage so everything else is covered now. My iPhone has also been connected to my Mac frequently, so I'm wondering whether an older computer backup might exist or whether recovery mode could preserve any data. Is there any legitimate option besides guessing the passcode and eventually erasing and restoring the phone?
3 Answers
There’s no reliable external method to unlock the phone through a Mac or another Apple device. If the passcode can’t be remembered, the data may be unrecoverable unless it exists in iCloud Photos, an iCloud backup, or a local computer backup. This is why keeping a current backup matters—device damage or loss could cause the same result even without a forgotten passcode.
Before trying another passcode, check carefully whether the photos are already covered by a backup. iCloud Photos and iCloud Backup are separate: if iCloud Photos was disabled, photos may be included in the device backup. If iCloud Photos was enabled, they should be available through the Photos service instead. A Mac may also have a local iPhone backup, but it is normally stored in the user Library under Application Support/MobileSync/Backup rather than being easy to find with a general system search. If you find one, don’t overwrite or delete it.
Unfortunately, there isn’t a workaround for bypassing the passcode. Once the remaining attempts are used, the usual option is to erase the iPhone and restore it from an iCloud or computer backup. Recovery mode also erases the device; it isn’t a way to preserve the data. You’ll still need the Apple Account credentials afterward because erasing does not remove Activation Lock.
Would putting it into recovery mode help in any way, or would that definitely erase everything? I was hoping it might preserve the photos.

I’m checking my Mac now because I’ve made local backups in the past to avoid paying for extra cloud storage. I was searching the system folders generally and couldn’t find anything, so I’ll look in that MobileSync backup location.