All secondary school pupils in Scotland will return to classrooms part-time from 15 March, First Minister Nicola Sturgeon has said.
It had previously been announced that those in S1 to S3 would not return to school until April.
But Ms Sturgeon said all secondary pupils will now get some in-school time before the Easter holidays.
Pupils in S4 to S6 who are studying for national qualifications are being prioritised for face-to-face learning.
It has also been confirmed that children in primary four to seven will return full-time from 15 March.
Ms Sturgeon also said the Scottish government would be considering if it was possible to speed up its plans to exit lockdown.
The first minister said there was a "clear expectation" that all secondary school pupils will return full-time after the Easter holidays.
She said the safety of staff and pupils was a "key priority", and that two-metre social distancing would continue in secondary schools until Easter.
Face coverings will need to be worn at all times, and schools are working to improve ventilation. Lateral flow tests will continue to be offered twice a week for all school staff as well as pupils in S4 to S6.
Some senior phase pupils have already returned to school on a limited basis to complete work for their qualifications, while P1 to P3 pupils have returned full-time.
Ms Sturgeon thanked all school leadership teams and staff, as well as parents, for all their efforts over the last few months.
She said: "My thanks to children and young people - I know how hard it must be to be separated from friends and teachers but you have all responded magnificently to all the difficulties of the last year and I hope you're looking forward to getting back to school later this month."
She added that local authorities would have "flexibility" to implement the phased return of pupils.
When presented with three options on schools, the Scottish government has opted for the one which covers the broadest ground.
It could have decided to send all pupils back at the same time in the middle of March, but this would have meant abandoning social distancing in secondary schools earlier than they would like.
It could have kept S1 to S3 out of class until the middle of April as originally planned, but this would have added to growing claims these youngest secondary pupils were being left behind.
Instead, it has decided to allow all pupils at least some time in class. So, for the first time, plans made last summer for so-called blended learning, which were never used, will be dusted off and put into practice in schools across the country - if only for a few weeks.
It's a more complicated option, but it's one the government thinks balances the wants and needs of young people and their families and the dangers and problems posed by the virus.
The latest figures showed that a total of 542 new positive cases of Covid-19 had been reported, 4.4% of those tested.
Ms Sturgeon said the data this week was "much more encouraging" than it was last week, when the decline in case numbers had appeared to slow down.
She said the average daily cases were now at their lowest level since October, average test positivity had fallen below 5% and hospital admissions were falling.
The first minister said she hoped to confirm changes to level four restrictions next week.
"Between now and then... we will be considering if it might be possible to accelerate the exit from lockdown in any way," she said.
Ruth Davidson, leader of the Scottish Conservatives at Holyrood, said pupils "deserve better than guesswork based on the SNP's drip feeding of partial information".
She welcomed the accelerated return of pupils, but said that observing Covid rules with full school buildings would pose "logistical questions".
She asked the first minister what solutions would be provided for campuses that did not have the space or staff to allow for two-metre social distancing.
Mental health support
Ms Sturgeon said the Scottish government was continuing to work with schools to ensure there was "good provision of remote learning", adding the funding available for local authorities would cover a range of improvements on top of ventilation.
New Scottish Labour leader Anas Sarwar said more than 1,500 children were on waiting lists for mental health support, and asked when the government would set out a national recovery plan for pupils.
Ms Sturgeon said transforming and redesigning child and adolescent mental health services had already begun before the pandemic, but that now had to be intensified.
Alison Johnstone, from the Scottish Greens, called for clarification on when additional support needs staff would be vaccinated, but Ms Sturgeon said deviating from the government's age-based approach would make decisions "political".
Scottish Liberal Democrat leader Willie Rennie said the "last-minute change" on schools had been made without issuing any fresh guidance, and said this had "dumped the problem on teachers to fix".
Meanwhile Scotland's largest teaching union, the EIS, said an "over hasty" return to full time schooling could risk a reversal of the progress made.
General secretary Larry Flanagan said the plan to return younger secondary pupils to blended learning did not recognise workload pressures this would create for "already exhausted" staff.
He added: "The announcement of a planned full return after Easter would suggest that physical distancing requirements currently in place for senior phase students may be removed despite the scientific evidence of the need for this mitigation.
"This will place those young people, and their teachers, at significant additional risk."