The option should be available by default. If you have an Apple ID tied to your user account on Mac, you can use it to reset password from the login window.
You’ll be able to use the new password after a restart. Lastly, change Mac password, create a hint to easily recollect it in future, and click save.Go to the main hard drive and choose your user account.Type “resetpassword” (in one word) and click Return.Next, choose Disk Utility > Continue > Utilities Terminal.Wait for the loading bar to appear on the screen while your Mac boots to Recovery. Turn off your computer and hold the power button + Command R.For such cases, there’s Apple’s Recovery Mode. There are no password hints and you can’t call it to mind, even though you’ve already tried to enter all pet names. You forgot Mac password and can’t access any of your accounts. Hope this is just a “what-if” for you, but let’s imagine it happened.