ほうがいいです "it is better (for you) to do..." is a sentence-final expression that can be used to give advice. It implies that if you do not follow the advice, danger or a problem will result. It refers to something very specific. When the advice is in the affirmative, ほうがいいです generally follows the past tense short form. When the advice is in the negative, the verb is in the present tense short form.
もっとやさいをたべたほうがいいですよ。 You'd better eat more vegetables.
じゅきょうをやすまないほうがいいですよ。 It is better not to skip classes.