If you forgot your Apple ID password - Apple Support
support.apple.com › en-us › HT201487Nov 19, 2021 · If your friend or family member uses iOS 9 through 12 and they can't download the Apple Support app, use the Find My iPhone app instead. Open the Find My iPhone app. When a Sign In screen appears, make sure the Apple ID field is empty. If you see someone else's user name, erase it. Tap Forgot Apple ID or Password, then follow the onscreen steps.
If you forgot your iPhone passcode - Apple Support
support.apple.com › en-us › HT204306Dec 03, 2021 · Step 3: Put your iPhone in recovery mode. iPhone X or later, iPhone SE (2nd generation), iPhone 8, and iPhone 8 Plus use the Side button. iPhone 7 and iPhone 7 Plus use the Volume down button. iPhone SE (1st generation), and iPhone 6s and earlier use the Home button. Press and hold the correct button for your iPhone while immediately connecting ...