From each according to his ability, to each according to his needs

"From each according to his ability, to each according to his needs" (Jeder nach seinen Fähigkeiten, jedem nach seinen Bedürfnissen) is a slogan popularised by Karl Marx in his 1875 Critique of the Gotha Programme. The principle refers to free access to and distribution of goods, capital and services. In the Marxist view, such an arrangement will be made possible by the abundance of goods and services that a developed communist system will be capable to produce; the idea is that, with the full development of socialism and unfettered productive forces, there will be enough to satisfy everyone's needs.

Origin of the phrase
The complete paragraph containing Marx's statement of the creed in the Critique of the Gotha Programme is as follows:

Although Marx is popularly thought of as the originator of the phrase, the slogan was common within the socialist movement. The origin of this phrasing has also been attributed to the French utopian Étienne-Gabriel Morelly, who proposed in his 1755 Code of Nature "Sacred and Fundamental Laws that would tear out the roots of vice and of all the evils of a society", including:

A similar phrase can be found in the Guilford Covenant in 1639:

Some scholars trace the phrase to the New Testament. In Acts of the Apostles the lifestyle of the community of believers in Jerusalem is described as communal (without individual possession), and uses the phrase "distribution was made unto every man according as he had need" (διεδίδετο δὲ ἑκάστῳ καθότι ἄν τις χρείαν εἶχεν):

Other scholars find its origins in "the Roman legal concept of obligation in solidum", in which "everyone assumes responsibility for anyone who cannot pay his debt, and he is conversely responsible for everyone else". James Furner argues: If $x$ = a disadvantage, and $y$ = action to redress that disadvantage, the principle of solidarity is: if any member of a group acquires $x$, each member has a duty to perform $y$ (if they can assist). All we then need to add, to get to the fundamental principle of developed communism, is to assume that non-satisfaction of a need is a disadvantage. The corresponding principle of solidarity in respect of need says: if any member of society has an unsatisfied need, each member has a duty to produce its object (if they can). But that is precisely what the principle 'from each according to their abilities, to each according to their needs!' dictates. In Marx's vision, the basic principle of developed communism is a principle of solidarity in respect of need.

Debates on the idea
Marx delineated the specific conditions under which such a creed would be applicable—a society where technology and social organization had substantially eliminated the need for physical labor in the production of things, where "labor has become not only a means of life but life's prime want". Marx explained his belief that, in such a society, each person would be motivated to work for the good of society despite the absence of a social mechanism compelling them to work, because work would have become a pleasurable and creative activity. Marx intended the initial part of his slogan, "from each according to his ability" to suggest not merely that each person should work as hard as they can, but that each person should best develop their particular talents.

Claiming themselves to be at a "lower stage of communism" (i.e. "socialism", in line with Vladimir Lenin’s terminology), the Soviet Union adapted the formula as: "From each according to his ability, to each according to his work (labour investment)". This was incorporated in Article 12 of the 1936 Constitution of the Soviet Union, but described by Leon Trotsky as an "inwardly contradictory, not to say nonsensical, formula".

As early as in 1900, Frederick Charles Hicks criticized the concept "according to his needs" as follows. There are no issues with this principle as long as there is enough of everything for everybody. But this is not the case and probably never will, because "man's wants tend always to outstrip his ability to supply them.... [Therefore] it will be necessary to have an agency for determining relative amounts of men's needs." Which will eventually lead to "absolutism and slavery".

In popular culture
In Ayn Rand's 1957 pro-capitalist novel Atlas Shrugged, a large and profitable motor company adopted this slogan as its method for determining employee compensation. The system quickly fell prey to corruption and greed, forcing the most capable employees to work overtime in order to satisfy the needs of the least competent and to funnel money to the owners. As a result, the company went bankrupt within four years.

In Margaret Atwood's 1985 novel The Handmaid's Tale, members of a dystopian society recited the phrase thrice daily. Notably the phrase is altered to read "From each according to her ability; to each according to his need", demonstrating a perversion of the phrase's original intention by Atwood's fictional society.

Mirroring the sentiment of Frederick C. Hicks, in Vladimir Voinovich's 1986 novel Moscow 2042, the slogan was parodied in the context of "communism in one city". In Moscorep (Moscow Communist Republic) Voinovich portrays various hilarious absurdities related to the implementation of the concept of "needs". The concept was introduced as follows: " 'I see,' I said. 'But who defines his needs? He himself?' - 'But this would be metaphysics, Hegelianism and Kantianism!' exclaimed Propaganda Paramonovna." Further, the protagonist was explained that a man is insufficiently qualified to determine his needs and special committees, "Pentagrams", do this.