The Ministry of Justice’s permanent secretary is to leave his job this summer when his contract ends, the department has confirmed.

Sir Richard Heaton is the latest in a string of senior civil servants to depart from their roles this year.

He will step down after a five-year tenure and nearly 30 years in the civil service, having previously confirmed his term was due to expire in August.

Last month he told the Commons Public Accounts Committee: “Whether or not I will continue beyond that will be the subject of an announcement, I dare say, in due course.”

Downing Street was rumoured to have retroactively vetoed an agreed extension to Sir Richard’s term, according to unverified media reports.

The news comes as it emerged Sir Mark Sedwill was step down as Cabinet Secretary, head of the civil service and national security adviser, amid reports of clashes with the Prime Minister’s chief aide, Dominic Cummings.

Sir Richard’s career in government began in 1991, when he joined the Home Office as a legal adviser.

He later spent five years at the Department for Work and Pensions as head of law and governance, and then as director general for pensions and ageing society.

In 2012 he was appointed permanent secretary of the Cabinet Office and in 2014 became the civil service race champion – leading work to improve ethnic diversity – before joining the MoJ in August 2015.

His departure adds to changes of permanent secretaries at other Government departments this year including the Home Office and Foreign and Commonwealth Office.

Sir Richard said it had been a “privilege” to lead the MoJ through “challenging years” adding: “But throughout, we have been able to deliver on the priorities of successive governments.”

Justice Secretary Robert Buckland described Sir Richard as an “exceptional civil servant, with the strongest of reputations across Government and the legal sector”, adding he was a “pleasure to work with”.

His praise was echoed by Mr Buckland’s predecessor David Gauke, who described Sir Richard on Twitter as “excellent official and always a wise source of advice”.

Sir Mark said Sir Richard had “earned the country’s appreciation for his three decades of dedicated public service and I would also like to thank him for his friendship and support as a colleague”, adding: “He leaves the department in good shape for the challenges ahead.”

Plans for his successor will be announced in due course.