Competition usually does benefit consumers, and the mechanism is reliable. A firm that charges more than its rivals loses customers, so prices are driven towards costs. A firm that neglects quality loses them too, so products improve. Firms compete by innovating, which over time delivers goods that did not previously exist. And competitive pressure forces costs down, so resources are not wasted. All of this happens because consumers have an alternative — and it is the existence of somewhere else to go, rather than any goodwill on the firm's part, that produces the result.
But there are real cases where it does not work that way.
Where competition is wasteful. In a natural monopoly, competing firms would duplicate expensive networks — two sets of water pipes down one street — which raises total costs. Consumers would pay more, not less, for the privilege of having a choice.
Where it drives down quality rather than price. Competing purely on price gives firms an incentive to cut corners on things consumers cannot easily judge: the safety of a building, the training of staff, the quality of an ingredient. Where buyers cannot assess quality before purchase, competition can produce a race to the bottom rather than better products, which is why food safety and building standards are regulated rather than left to competition.
Where the costs are pushed onto others. A firm cutting costs to undercut rivals may do so by polluting more or paying less. Consumers gain cheaper goods while bearing the cost as residents, and firms that behave responsibly are undercut by those that do not — so competition actively spreads the bad practice.
Where it is too intense to sustain. A price war may drive most firms out, and the survivor is then a monopoly able to raise prices above where they started. Short-run benefit becomes long-run harm.
And competition can be wasteful in its means. Firms spend enormous sums on advertising largely to take customers from each other, which raises costs without producing anything consumers value.
My judgement is that competition benefits consumers where they can judge what they are buying and where the costs of production fall on the firm. Those two conditions are what make the mechanism work: consumers must be able to identify the better offer, and the firm must bear the full cost of providing it.
Where both hold — most ordinary consumer goods — competition is reliably beneficial and intervention would make things worse. Where either fails, competition can drive quality down or push costs onto third parties, and consumers need regulation as well as choice. That is why economies with the most competitive markets also have extensive consumer protection and environmental law: the two are complements, not alternatives, and the regulation exists to make the conditions for beneficial competition actually hold.