- May is the second female PM after Thatcher
- Her first task will be navigating Britain's exit from the bloc
- In her first speech as PM, she promised to fight injustice
- Johnson appointed foreign secretary, Hammond named chancellor
After weeks of turmoil in British politics following the EU referendum, Theresa May, a Conservative politician, has become Britain's second female prime minister.
May, 59, accepted an invitation from Queen Elizabeth II on Wednesday to form a new government just minutes after David Cameron, the outgoing prime minister, tendered his resignation.
"The government I'll lead will be driven not by the interests of the privileged few, but by yours," said May, as she arrived at 10 Downing Street from Buckingham Palace.
READ MORE: Where does Theresa May stand on Brexit and immigration?
In a surprise move, May named Boris Johnson, former London mayor and prominent figure in the victorious "Leave" campaign in Britain's EU referendum as foreign secretary.
Johnson's role in Britain's negotiations over its future relationship with the EU is likely to be limited because May is expected to create a new ministerial post focused exclusively on Brexit issues.
Nevertheless, as foreign minister, Johnson, who has never previously held a cabinet post, will have to address questions about the country's role in the world after its exit from the EU and he will inherit Britain's often difficult relationship with Russia.
Meanwhile, Philip Hammond was appointed chancellor, replacing George Osborne.
|Until Wednesday, May was the home secretary under Prime Minister David Cameron [AP]
May is the second female prime minister after Margaret Thatcher, also a Conservative politician, who led the country from 1979 until 1990.
In her first speech as prime minister, May promised to fight against "burning injustice", citing difficulties of young white working class men in attending university, black Britons when they need to use the criminal justice system, women in the workplace, mental health patients and young people who hope to own their own homes.
David Cameron's "true legacy is not about the economy but about social justice", she said. "In that spirit, I also plan to lead."
Her appointment comes amid weeks of uncertainty after millions of Britons went against her advice, and that of Cameron, and voted to leave the European Union.
Until Wednesday, May was the home secretary.
Having failed to convince Britons to vote to remain in the EU, Cameron resigned, opening the way for a brief leadership contest.
Al Jazeera's Barnaby Phillips, reporting from London, said that May was disadvantaged because she did not have much time to form her cabinet.
"The process has been truncated," our correspondent said.
Foreign Secretary: Boris Johnson
Home Secretary: Amber Rudd
Chancellor: Philip Hammond
Sec. of State for Exiting EU: David Davis
International Trade Secretary: Liam Fox
Defence Secretary: Michael Fallon (kept his job)
Chancellor George Osborne, meanwhile, is out of a job
Now that she is prime minister, May will learn the details of Britain's nuclear deterrent and has started to receive congratulatory phone calls from fellow world leaders.
German Chancellor Angela Merkel called May and vowed to continue friendly relations. French President Francois Hollande also rang the new leader and said negotiations for Britain leaving the EU should be as quick as possible.
European Commission President Jean-Claude Juncker also urged May to swiftly engage in divorce talks with the EU.
The outcome of the UK vote "has created a new situation which the United Kingdom and the European Union will have to address soon," Juncker said in a letter to May published on his Twitter account.
"I wish you every success in the task ahead," he added.
European Parliament President Martin Schulz also piled on the pressure as he congratulated May.
The White House was quick to congratulate May and said it was confident in her ability to steer Britain through negotiations on leaving the EU.
"Based on the public comments we've seen from the incoming prime minister, she intends to pursue a course that's consistent with the course that President Obama has offered," White House spokesman Josh Earnest said at a news briefing.
Earlier, at Prime Minister's Questions - a weekly session, Cameron said May was "a brilliant negotiator".
His advice to her, regarding the EU, was "to be as close to the European Union as we can be for the benefits of trade, cooperation and security ... The Channel will not get any wider once we leave the European Union, and that is the relationship we should seek."
Source: Al Jazeera and agencies