The UK’s biggest banks are facing mounting calls for a windfall tax after reporting bumper half-year profits, putting the new prime minister, Andy Burnham, under immediate pressure to use the gains to ease the cost-of-living crisis.

HSBC, NatWest, Barclays and Lloyds, Britain’s four largest lenders, collectively reported £29.2bn in profits for the first six months of the year. Almost half of that total, £13.7bn, is being handed to shareholders through dividends and share buybacks, while the strong earnings have also allowed executives to increase bonus pots.

The surge in profitability has been driven by high interest rates and by market turbulence spilling over from the United States’ military campaign against Iran, which has boosted trading activity as well as lending incomes. The scale of the returns has reignited the debate over whether banks should be required to contribute more to the public finances at a time when many households are still feeling the effects of high prices.

Supporters of a windfall tax say a well-designed levy on bank profits could raise about £19bn, a sum that would go a long way toward funding Burnham’s cost-of-living agenda. The prime minister has not yet committed to the measure, but pressure is expected to intensify as the scale of the lenders’ profits becomes clearer.

The sums involved are striking and underline how lucrative the past six months have been for Britain’s largest lenders. The decision by banks to return almost half of their earnings to investors is likely to sharpen the political argument, particularly while household budgets remain under strain.

History suggests that Burnham would face a fierce fight if he chose to follow the windfall tax route. Earlier political battles over bank profits have shown how determined lenders and their allies can be in resisting new levies, and any attempt to impose a windfall charge is likely to meet similar opposition. The question is whether the strength of public concern about the cost of living can outweigh that resistance.

The debate presents an early political test for the new prime minister. Burnham has built much of his political reputation around his response to the cost-of-living crisis, and the announcement of record bank profits has given fresh momentum to campaigners who argue that the sector should share more of its gains. With the four largest lenders reporting combined profits of nearly £30bn in the first half of the year, the question of who benefits from that wealth is unlikely to fade from the political agenda.

There has been no commitment from Downing Street so far on a windfall tax. But the combination of soaring bank profits, stretched household budgets and a new prime minister determined to act on living standards is a powerful backdrop for one of the most significant economic policy debates of his early premiership.