Good question, Jame.
Here is what the Cambridge Dictionary says: "We use had better to refer to the present or the future, to talk about actions we think people should do or which are desirable in a specific situation. The verb form is always had, not have. We normally shorten it to ’d better in informal situations. It is followed by the infinitive without to:
It’s five o’clock. I’d better go now before the traffic gets too bad.
Not: I’d better to go now.
The democratic movement had better concentrate on the immediate issues of the economy and security. (more formal)
Had better is a strong expression. We use it if we think there will be negative results if someone does not do what is desired or suggested:
She’d better get here soon or she’ll miss the opening ceremony."
There is more information about this phrase here: https://dictionary.cambridge.org/grammar/british-grammar/had-better
I hope this is enough detail for you.