A-level and GCSE students in England, Wales and Northern Ireland are to be given grades estimated by their teachers and not those based on an algorithm after the government was forced into a massive U- turn.

The government’s dramatic shift in position follows outrage across the country after about 40% of A-level results were downgraded by Ofqual, the exams regulator. Ofqual used a formula based on mock results and schools’ prior grades to award grades last week after the decision to cancel exams due to the pandemic. The new modelling meant that many students dropped several grades from their predicted marks, leaving them unable to take up their university offers.

Despite the U-turn and the apologies, calls for Gavin Williamson, the education secretary, to resign mounted across the political specturm. Whether the U-turn is enough to save his scalp is not yet clear, but there is deep unhappiness on the government’s own benches about what is seen as a totally unnecessary fiasco.

There were also questions being asked about the competence of Ofqual, chaired by Roger Taylor, and its members, who worked with the government and unions on coming up with the new modelling process.

Announcing the shift to teachers’ assessments, Williamson said: “It is clear that the process of allocating grades has resulted in more significant inconsistencies than can be resolved through an appeals process. We now believe it is better to offer young people and pedants certainty by moving to teacher assessed grades for both A and AS level and GCSE results.”

Acknowledging the political toxicity of the situation, he added: “I am sorry for the distress this has caused young people and their parents but hope this announcement will now provide the certainty and reassurance they deserve.”

This is a drastic change in tone from Williamson, who two days ago said that there would be “no U-turn, no change” over the algorithm. That position crumbled this morning as the government faced increasingly vocal pressure from senior Conservative backbenchers. Robert Halfon, the Conservative chair of the Commons Education Committee, urged the Prime Minister to “get up and set out a plan”, while Penny Mordaunt, the former Defence Secretary, tweeted that she had “made my views on GCSE results known to the Department for Education.”

The algorithm for moderating grades had been agreed by teachers in a consensual process and voluntarily adopted by the devolved administrations. In the event, however, the political consequences of downgrading a student’s predicted grade on the basis of their school’s previous performance was politically untenable; it meant that some young people were punished for living in a deprived area. First Minister Nicola Sturgeon faced this problem early on, as Scottish results were released a week before the rest of the country. She faced extreme pressure from all sides of political debate and announced a U-turn days later.

Learning from the Scottish experience, there was an attempt by Williamson to pre-empt the incoming wave of outrage. The announcement of a “triple lock” for students was hastily released two nights before the results were delivered, allowing students to either use mock exam results or request a free resit. But this was a botched job – when results day arrived, the appeals process to access the new options had yet to be devised.

In the wake of today’s national U-turn, Education Secretary Gavin Williamson finds himself in a particularly vulnerable position. Having been sacked as Defence Secretary by Theresa May for allegedly leaking government secrets, and perceived to be an overbearing Chief Whip under David Cameron, the Education Secretary already has few allies in the Commons. Now, amidst calls for him to resign, he also has few people willing to defend him.

The experience has also reignited criticism of Boris Johnson and Dominic Cummings’ approach to government. Williamson was rewarded with the Cabinet position not because he had a reputation for educational expertise, but because he had helped Johnson in the Conservative leadership contest. As with many of its other appointments, Downing Street prioritised loyalty over all else.

That was an understandable strategy for a peacetime government with a large majority. But in a global pandemic, that lack of expertise has been conspicuous and costly.