London — British Prime Minister Boris Johnson says he has tested positive for the new coronavirus, becoming the first world leader to confirm a diagnosis.

"I've developed mild symptoms of the coronavirus. That's to say, a temperature and a persistent cough. And on the advice of the chief medical officer, I've taken a test that has come out positive. So I am working from home, I'm self isolating, and that's entirely the right thing to do," he said in a video message posted to his official Twitter account.

Over the last 24 hours I have developed mild symptoms and tested positive for coronavirus. I am now self-isolating, but I will continue to lead the government’s response via video-conference as we fight this virus. Together we will beat this. #StayHomeSaveLives pic.twitter.com/9Te6aFP0Ri — Boris Johnson #StayHomeSaveLives (@BorisJohnson) March 27, 2020

Johnson said he was able to continue carrying out his duties despite his illness.

Get Breaking News Delivered to Your Inbox

"Be in no doubt that I can continue, thanks to the wizardry of modern technology, to communicate with all my top team to lead the national fight back against coronavirus," he said.

If he becomes too ill to work, however, it has been agreed that Foreign Secretary Dominic Raab will take over until he recovers.

Johnson thanked everyone in the U.K. working on the response to the epidemic, stressing the way to get through it was to follow government advice to stay at home.

"Thank you to everybody who's doing what I'm doing, working from home to stop the spread of the virus from household to household. That's the way we're going to win. We're going to beat it and we're going to beat it together. Stay at home, protect the NHS, and save lives," he said.

Britain's prime minister has been delivering daily press conferences to the nation, which, until recently, saw him gathering with journalists and top medical and government officials. Over the past few days, the government has started hosting the press conferences remotely, with journalists asking questions via video link to officials at Downing Street, who have stood at a significant distance from one another.

Following medical advice, I was advised to test for #Coronavirus. I‘ve tested positive. Thankfully my symptoms are mild and I’m working from home & self-isolating. Vital we follow the advice to protect our NHS & save lives#StayHomeSaveLives pic.twitter.com/TguWH6Blij — Matt Hancock (@MattHancock) March 27, 2020

Not long after Johnson confirmed his diagnosis, Britain's Health Secretary Matt Hancock also posted a video to Twitter confirming his own positive test for COVID-19. Later on Friday, Britain's chief medical officer, Chris Witty, said he was showing symptoms and would self-isolate for 7 days.

Johnson reportedly started exhibiting symptoms Thursday night, a day after he participated in a weekly question-and-answer session in Britain's parliament. It was not immediately clear how many lawmakers and other government staff would go into to self-isolation following his and Hancock's diagnoses.

Queen Elizabeth, who holds regular weekly meetings with every Prime Minister, did so with Johnson over the phone this past Wednesday, according to the Royal Family twitter account. Buckingham Palace said the last time the queen saw Johnson in person was on March 11, and that she remained in good health as of Friday. Her son Prince Charles, who is next in line for the British throne, tested positive for COVID-19 earlier this week.

Johnson's representative said he was self-isolating in his apartment, and that his meals would be left outside his door by Downing Street staff. The representative would not confirm whether Carrie Symonds, Johnson's pregnant fiancee, is currently living with him.

Johnson has been accused by some opponents of an inadequate initial response to the coronavirus outbreak in the U.K., however his own diagnosis with COVID-19 comes at the end of a week that has seen the government step up containment measures significantly, ordering people to remain in their homes for all but essential tasks for at least three weeks.