British Prime Minister Boris Johnson has ordered people to stay at home to try to halt the spread of coronavirus, closing alll but essential shops, and warning that those who do not follow the rules will face fines.

"From this evening, I must give the British people a very simple instruction: you must stay at home," Johnson said on Monday in a prerecorded televised address to the nation, replacing his usual daily news conference.

As deaths from the virus in the United Kingdom jumped to 335, Johnson said people would only be allowed to leave their homes to exercise, shop for basic necessities, address a medical need, provide care for others, or travel to and from work where absolutely necessary.

Almost 7,000 people have been infected with coronavirus so far in the country, home to about 66 million.

More:

"That's all - these are the only reasons you should leave your home," Johnson said, adding that people should not meet friends or family members who do not live in their homes.

"If you don't follow the rules, the police will have the powers to enforce them, including through fines and dispersing gatherings," he warned.

The new measures would be reviewed in three weeks, and relaxed if possible.

The government will close all shops selling non-essential goods, Johnson said, including clothing stores, as well as other premises including libraries, playgrounds and outdoor gyms, and places of worship.

Advice to stay at home and avoid social gatherings went unheeded over the weekend by millions who took advantage of sunny weather to flock to parks and beauty spots, ignoring instructions to stay two metres (six feet) apart.

Under the new measures, the government will stop all gatherings of more than two people in public who do not live together, and stop all social events, including weddings and baptisms but not funerals.

Parks would remain open for exercise but gatherings would be dispersed, Johnson said.

"It brings the UK in line with measures seen in plenty of other countries around Europe," said Al Jazeera's Rory Challands. "For much of this crisis, the UK has been a step or two behind other countries. There were plenty of people in the UK saying, 'Why can't we see the same measures?'."

Italy, now the global epicentre of the crisis with most coronavirus deaths and a quickly rising number of patients, is currently under complete lockdown.

Spain and France have similar measures in place to contain the spread of the infection.

"Without a huge national effort to halt the growth of this virus, there will come a moment when no health service in the world could possibly cope; because there won't be enough ventilators, enough intensive care beds, enough doctors and nurses," Johnson said in his address.

Separately, an emergency bill giving authorities sweeping powers to tackle the outbreak, including the right to detain people and put them in isolation to protect public health, passed through the House of Commons.

The legislation will go before the House of Lords on Tuesday.

Earlier, in a pleading request to increase supplies of personal protective equipment, more than 6,000 front-line doctors warned they felt like "cannon fodder" and were being asked to put their lives at risk with out-of-date masks, and low stocks of equipment.

Health Secretary Matt Hancock admitted there had been issues, but promised action was being taken. He said the army would drive trucks throughout the day and night to get supplies to medical staff.

"It's like a war effort - it is a war against this virus and so the army have been incredibly helpful in getting those logistics so we can get the supplies to protect people on the front line," he told the BBC, saying the health service now had 12,000 ventilators, 7,000 more than at the start of the crisis.

The government on Monday also urged all Britons travelling abroad to return home. However, this would not be possible for all, since some countries have closed their borders.