I'm locked out of my son's iMac since I forgot my admin password, and now I'm stuck because I've already tried several times to recover it. Each attempt makes me wait an hour, and it's asking for a recovery code that I don't remember ever creating. I really want to avoid deleting everything and reinstalling macOS, so are there any alternatives I can explore?
4 Answers
There really aren’t any easy workarounds for this. Apple designed their security with multiple layers to keep your info safe. Remembering the password or doing a full reinstall is usually the only way out of this situation. If you have an older Intel model, there might be some slim chances to recover data, but it’s risky.
It sounds like the recovery code is something you might have set up long ago but forgot to write down. Deleting and reinstalling won't help if the activation lock is in place. You’d need the original receipt to get Apple to unlock the iMac for you. Sorry to say, it's a tough spot to be in.
Unfortunately, your options are quite limited. Apple's security policies are pretty tight, and if you can't remember your password, you won't be able to access the files on the computer unless you delete everything and reinstall the operating system. If the device is linked to iCloud with an Activation Lock, you'll need to contact Apple with proof of purchase to get it reset. Unfortunately, you can't bypass the security without losing data.
Sounds like you might have FileVault enabled. In that case, access to your files is going to be highly restricted without the password or recovery key. You can check Apple's support page on FileVault for any tips, but it's best to have the right codes.

Related Questions
Can't Load PhpMyadmin On After Server Update
Redirect www to non-www in Apache Conf
How To Check If Your SSL Cert Is SHA 1
Windows TrackPad Gestures