‘Complement’ and ‘compliment’ are sometimes confused because they are pronounced the same and have very similar spellings. Both function as noun and verb, but are quite distinct in meaning.
As a noun, ‘compliment’ refers to an expression of esteem, admiration or praise. For example, to call someone handsome/beautiful is to pay him/her a compliment, and the verb refers to this action, ie, the paying of a compliment.
On the other hand, as a noun, the ‘complement’ of something supplies what that something is missing, ie, completes or perfects it. For example, wine can be said to complement a meal.