Lockdown restrictions will come into force in Cardiff and Swansea county areas and also the town of Llanelli.
They will come into effect in Llanelli, Carmarthenshire, on Saturday at 18:00 BST and in Wales’ two biggest cities on Sunday from 18:00.
It means 1.5 million people, about half the population, will be under lockdown.
But cases in Caerphilly, the first area to lockdown, have reduced significantly, Health Minister Vaughan Gething said.
The restrictions will be the same as those already affecting people living in Merthyr Tydfil, Bridgend, Blaenau Gwent, Newport, Rhondda Cynon Taf and Caerphilly, which are already in lockdown.
Mr Gething said people in Cardiff and Swansea should not “treat this weekend as a big blow-out”.
He also said cases in Carmarthenshire had “overwhelmingly” been linked to Llanelli, with eight out of 10 cases there.
“In Llanelli we have a particular challenge around the town that is well identified, a significant spread that is not in control,” he said at a Welsh Government press conference.
“We’ve spoken to the local authority, we’ve spoken to the local health board and we understand the need to act and act as soon as possible.
“If the same prevalence rates were in Cardiff and Swansea then the rates of infection would be much much higher.”
He described a “balanced judgement” being taken that the rules should come into force in Cardiff and Swansea a day later to “allow people to plan”.
In the last seven days, 85 of 109 cases in Carmarthenshire have been in Llanelli where the rate of infection is 151.6 per 100,000 people, compared to 57.7 in the wider county.
The Llanelli lockdown is the first not to cover a whole local authority area. A postcode finder will be made available online to make clear which areas are under lockdown, said Mr Gething.
The majority of cases in Llanelli have been linked to people socialising without social distancing.
Burry Port, which is also in Carmarthenshire, will not be included in the area under restrictions.
What about university students?
As students return, Mr Gething said the effect on university towns will be monitored.
He said: “One of the things we’ll need to do is to understand how the pattern is changing within those university towns and cities once students have been there for a period of time.
“At this point in time with a large movement of people across the UK, we need to understand what that does in terms of local prevalence so I don’t think now is the time to make a definitive choice about what would happen in the end of your recess but it’s an obvious question for us to consider.”
What can I do?
Under the rules, nobody is able to enter or leave the eight counties and one town without a “reasonable excuse”.
People are allowed to travel to outside the area for a limited number of reasons.
These include going to work if they are not able to work from home, to go to school, give care and buy food or medical supplies.
What about areas not locked down?
Ministers and officials said they would look at data over the weekend before deciding whether restrictions needed to be extended to Neath Port Talbot, the Vale of Glamorgan and Torfaen, he added.
Meetings will also take place next week with council leaders in north Wales, where Mr Gething said the picture was “more mixed”.
Only a part of Carmarthenshire is going to be locked down from Saturday.
Leader Emlyn Dole said: “It is worrying to see how sharply the number of positive cases has risen in the Llanelli area, and action has had to be taken to help stop the spread and break the chain of infections concentrated in this area to prevent a whole county lockdown.
“We must all do the right thing, follow the advice and protect each other. In parts of Llanelli, we’re asking people and businesses to make even greater sacrifices – we fully appreciate the impact this will have, but there is no other way. We must stop the spread.”