Donald Trump has appointed a new acting chief of staff after a protracted and chaotic search to replace John Kelly.

The US president turned to his budget director, Mick Mulvaney, to temporarily fill a position once seen as one of the most sought-after in the White House.

It will be Mr Mulvaney’s third job in Mr Trump’s government. He is currently head of the Office of Management and Budget (OMB), and for a time simultaneously led the Consumer Financial Protection Bureau.

“Mick has done an outstanding job while in the administration,” tweeted the president as he announced the news on Friday.

The pair’s existing relationship was key to the appointment; Mr Trump likes Mr Mulvaney personally and they are said to get on well. Whether the president has seen video footage of his new chief of staff calling him "a terrible human being" in 2016 is unclear.

Mr Trump is said to prize the former congressman's knowledge of Capitol Hill and political instincts, which he believes could be valuable as his administration prepares for a Democratic-controlled House of Representatives and the 2020 election campaign.

Mr Mulvaney, a former lawyer and restaurant chain owner, entered politics in 2006, when he was elected to the South Carolina House of Representatives, and later became a state senator.

In 2010 he was elected to the US House as Representative for the South Carolina's 5th district, a seat he held until his appointment as OMB director in January 2017.

While in congress, he founded the staunchly conservative House Freedom Caucaus voting bloc, which recently called on Mr Trump's administration to allocate $5 billion ($4 billion) in funding to build a wall to prevent migrants crossing the southern US border.

Mr Mulvaney opposed the Affordable Care Act, known as Obamacare, as well as gun control and government funding for abortion services.

Trump nominee Mick Mulvaney admits Obama's inauguration crowd size was bigger

As head of the OMB, he has pushed conservative policies including benefit and tax cuts.

“I don’t think anyone in this administration is more of a right-wing conservative than I am,” he told Politico last year.

His first words upon meeting Mr Trump’s senior economic adviser, Gary Cohn, were reportedly: “Hi, I’m a right-wing nutjob.”

In March last year, Mr Mulvaney claimed without evidence that Barack Obama’s administration had manipulated unemployment figures to make the economy look stronger than it actually was – something that FiveThirtyEight’s Ben Casselman noted “would require a conspiracy theory of massive proportions, involving hundreds if not thousands of people”.

Mr Mulvaney has been appointed chief of staff on an interim basis. The White House has not said how long he will hold the position, or why his appointment is not permanent. But Mr Mulvaney is said to have been reluctant to sign up long term to a job now seen as a poisoned chalice.