New Zealand's largest city, Auckland, will close from 12 noon on Wednesday after Prime Minister Jacinda Ardern warned four new cases of coronavirus.
The country had hit a record 102 days with no new transmissions and was widely viewed internationally as a role model for fighting the virus.
Auckland citizens are expected to work from home unless they are key workers. Schools will be closed, as will bars, cafes and restaurants until the end of the week.
Ardern said in a televised press conference: "We are asking the people of Auckland to stay home to stop the spread.
"Act like you have COVID and like the people around you have COVID."
The country had reacted hard and quickly to respond to the pandemic, banning non-New Zealand nationals traveling from China before there were cases in the country. Those nationals who had traveled from China had to be quarantined for 14 days.
A month later in March, all visitors to New Zealand were forced to self-isolate for 14 days and the borders were practically closed. A warning system from 1 to 4 has been implemented, with 4 being the most severe. Ardern warned Wednesday that the whole country would not be on level 2 alert.