Compensation means "making up for something." When a restaurant offers you a free dessert as compensation for messing up your dinner order, the hope is that you will leave happy (and refrain from writing a negative review online).
Compensation can also be money, a payment meant to give someone a fair exchange for their effort and output. In fact, the word comes from the Latin word compensat-, meaning "weighed against." If you receive fair compensation for your work, the money is equal to your time and effort. In other words, the scale is balanced.