The former International Trade Secretary was pictured arriving at the Foreign, Commonwealth and Development Office this morning for her first day in the post.
Mr Raab, 47, was appointed in 2019 and stood in for the prime minister when Mr Johnson was sick with Covid-19 last year.
But he was heavily criticised over his response to the fall of Afghanistan, which played out while he was on holiday in Greece.
He will move to the post of Justice Secretary and take on the title of Deputy Prime Minister, which had been vacant since 2015.
His justice role means he will also take on the ancient title of Lord Chancellor, but the move from the Foreign Office was widely seen as a demotion. He declined to comment as he left Mr Johnson’s Downing Street office.
Ms Truss, 46, will keep a separate brief as Minister for Women and Equalities alongside her foreign affairs role.
As trade minister, she has been the public face of Britain’s post-Brexit trade talks with countries such as the US and Canada.
The opposition Labour Party had called for Mr Raab’s sacking after it emerged he had delegated a phone call to Kabul in the hours before the Taliban takeover. The conversation ultimately never took place.
Mr Raab later said he would not have taken the holiday in hindsight but defended his handling of the crisis in Afghanistan.
He acknowledged that Britain, like other countries, had been caught out by the speed of the Taliban advance after Nato forces withdrew their troops.
His role as Justice Secretary will be his third separate brief in the Cabinet, after a spell as Brexit Secretary under former prime minister Theresa May.
Mr Raab stood for the Conservative leadership after Mrs May resigned, but was eliminated in the second round of voting.
The post of deputy prime minister has no formal responsibilities. It was last held by Nick Clegg during the Conservative-Liberal Democrat coalition from 2010 to 2015.
Following the reshuffle, the Prime Minister said it is time for ministers to "get on with the job".
He tweeted: "The Cabinet I have appointed today will work tirelessly to unite and level up the whole country.
"We will build back better from the pandemic and deliver on your priorities. Now let’s get on with the job."
In other replacements, Baghdad-born Nadhim Zahawi replaced Gavin Williamson as Education Secretary. In November last year, Mr Zahawi, 54, was asked to oversee the UK’s Covid-19 vaccination campaign.
Mr Williamson’s time in office was tainted by the chaos surrounding last year’s exams which saw the government make multiple U-turns in policy.
As the pandemic caused exams to be cancelled, England employed an algorithm to standardise grades for A-levels and GCSEs.
The system caused uproar among teenagers, their families and some teachers, with many complaining it had unfairly punished students.
Justine Greening, who was education secretary from 2016 to 1018, touched on Mr Williamson’s sacking in an interview with Sky News this morning.
She said since the pandemic rolled in “there were decisions made and mistakes made” by Mr Williamson which “very much led” to him being sacked.
She said the Prime Minister “needs to have someone with grip, vision and energy” in the post to “drive forward the education brief” because education is at the heart of his levelling up agenda.
Ms Greening added: “Clearly Boris Johnson sees this as a fresh period for his government, quite rightly, and he wants to have the right team in place to succeed.”
Defence Secretary Ben Wallace insisted Mr Johnson did not sack MPs from Cabinet because of their incompetence and said characterisations of Mr Williamson have been “unfair”.
He told BBC Breakfast: “He has removed people from Government not because they’re incompetent, not because they weren’t loyal enough et cetera, which are often the narratives you see, but often he has to refresh his team and move people out the way.”
Sir Michael Wilshaw, former head of Ofsted, said the top priority for Mr Zahawi as he enters office should be to address the inequality among students which has gotten “significantly worse” since the Covid pandemic hit.
Sir Michael told BBC Radio 4’s Today programme that Mr Williamson’s successor should “make sure that the disadvantaged do significantly better” in England’s education system.
Former Tory MP and attorney-general Dominic Grieve, 65, told Sky News this morning that he believed the Prime Minister reshuffled his Cabinet because it was “not functioning" but said there could be no noticeable difference unless he shifted his “chaotic” style of governance.
Conservative party co-chairwoman Amanda Milling was also removed, weeks before the annual Conservative party conference.
Michael Gove replaces Robert Jenrick at the Ministry of Housing, Communities and Local Government, while also taking on cross-government responsibility for Mr Johnson’s “levelling up” agenda to shift the balance of power between central and local government.
Nadine Dorries was made Culture Secretary replacing Oliver Dowden, who in turn replaces Ms Milling as co-chairman of the Conservatives, as well as holding the title of Minister without Portfolio.
There are also some non-movers in the Cabinet line-up.
Chancellor Rishi Sunak, Home Secretary Priti Patel, Health Secretary Sajid Javid, Transport Secretary Grant Shapps and Defence Secretary Ben Wallace are all staying in post, while Business Secretary Kwasi Kwarteng and Northern Ireland Secretary Brandon Lewis also retained their jobs.