The origin of altruism is a fundamental problem in evolution, and the maintenance of biodiversity is a fundamental problem in ecology. These two problems combine with the fundamental microbiological question of whether it is always advantageous for a unicellular organism to grow as fast as possible. The common basis for these three themes is a trade-off between growth rate and growth yield, which in turn is based on irreversible thermodynamics. The trade-off creates an evolutionary alternative between two strategies: high growth yield at low growth rate versus high growth rate at low growth yield. High growth yield at low growth rate is a case of an altruistic strategy because it increases the fitness of the group by using resources economically at the cost of decreased fitness, or growth rate, of the individual. The group-beneficial behaviour is advantageous in the long term, whereas the high growth rate strategy is advantageous in the short term. Coexistence of species requires differences between their niches, and niche space is typically divided into four 'axes' (time, space, resources, predators). This neglects survival strategies based on cooperation, which extend the possibilities of coexistence, arguing for the inclusion of cooperation as the fifth 'axis'. Here, individual-based model simulations show that spatial structure, as in, for example, biofilms, is necessary for the origin and maintenance of this 'primitive' altruistic strategy and that the common belief that growth rate but not yield decides the outcome of competition is based on chemostat models and experiments. This evolutionary perspective on life in biofilms can explain long-known biofilm characteristics, such as the structural organization into microcolonies, the often-observed lack of mixing among microcolonies, and the shedding of single cells, as promoting the origin and maintenance of the altruistic strategy. Whereas biofilms enrich altruists, enrichment cultures, microbiology's paradigm for isolating bacteria into pure culture, select for highest growth rate.