In the phrase, "it better be good", what part of speech is ”better”?

Clearly the verb in the sentence in "it better be good" is "be", but what is "better"? Is it an auxiliary or an adverb?


"Better" is here an adverb.

(OALD) adv. 3 used to suggest that sth would be a suitable or appropriate thing to do The money could be better spent on more urgent cases. You'd better tell her before someone else does.

In the case of your sentence the adverb takes on a special meaning not mentioned. In saying "It better be good!" someone is stating that in case of being deceived by a quality lower than what one is in right to expect there'll be no leniency on the part of the speaker or on the part of someone eles who is concerned, etc.

Of course, there exists a verb, "to better", but here you can discard the possibility of "better" being the verb, as if it were, you'd have instead "it betters".

Important additions due to users John Lawler and BoldBen; they situate this idiom more precisely, and generally.

The idiom is "had better" (always past tense, always comparative). "Had" is often ellipted in everyday talk, since the /db/ sequence of (for instance) "You'd better leave now" gets reduced to just b in better. The result is that many people never learn that one can (not to say "should") use "had" with "better" in this sense. (John Lawler)
[In "It better < some verb >…", "They'd better < some verb >…", etc.] there is always an implication of unpleasant consequences [if the action of the verb or the state it indicates is not realized in due time]. (BoldBen) [A] threat [is implied], though not always personal. [this idiom] works fine for anything that's necessary. Example: We'd better stay indoors today with all the smoke in the air. (John Lawler)