Labour power is the capacity of people to work. The expenditure of labor power consumes energy, and it must be constantly reproduced. The amount of labour needed to reproduce labour power is called necessary labour. In a sufficiently productive society, labour power produces more than it needs for it to be reproduced, and surplus labour arises. The aggregate surplus labour of society as a whole is called the surplus product, as opposed to the necessary product, which is just the labour needed to reproduce labour power. The surplus product may be used to improve the means of production, to produce luxury goods, or to sustain those in society who are not producing.
In societies with a commodity form, where labour takes the form of value, labour power becomes a very important commodity. Its use-value is the ability to produce value, and its value is given by its cost of reproduction, which in turn depends on the value of basic necessities.
Under capitalism, where the bourgeoisie owns the means of production, the proletariat cannot subsist on its own, and workers need to sell their labour power to a capitalist in exchange for monetary wages, which only account for necessary labour, and not the total labour contributed, giving rise to exploitation. Surplus labour takes the form of surplus value, which the capitalist appropriates. The longer the workday and the greater the productivity and labour intensity, the more surplus value the capitalist can extract. Wages also depend on factors such as skill, supply and demand, and the bargaining power of the proletariat.
In a socialist society, there is no longer a capitalist class. As a consequence, workers are compensated for the full value of their labour, and exploitation is abolished. Some deductions may be made in order to provide certain services to those who need them.