If you forgot the passcode on your iPhone, or your iPhone is disabled -
How to reset your passcode without a computer if you have iOS 15.2 or higher.
How to reset your iPhone, iPad, or iPod touch when you forgot your passcode - Apple Support
How to reset your passcode using a computer.
If you forgot your iPhone passcode - Apple Support