JEDDAH, Saudi Arabia—Millions of Saudi children began returning to elementary school and kindergarten classrooms Sunday for the first time in nearly two years, a period of remote learning that was among the world’s longest and that angered parents.

For some Saudis and foreign workers, the return to the classroom was a relief. Parents said their children faced learning difficulties and emotional setbacks during distance learning, and they grew frustrated as they watched neighboring countries ease restrictions on classroom learning...

JEDDAH, Saudi Arabia—Millions of Saudi children began returning to elementary school and kindergarten classrooms Sunday for the first time in nearly two years, a period of remote learning that was among the world’s longest and that angered parents.

For some Saudis and foreign workers, the return to the classroom was a relief. Parents said their children faced learning difficulties and emotional setbacks during distance learning, and they grew frustrated as they watched neighboring countries ease restrictions on classroom learning last year.

Others said they were anxious that resuming in-person learning would cause their children to get sick or spread the virus, as the Omicron variant sends Saudi case levels to record highs.

The kingdom didn’t see a rise in cases when middle and high schools reopened in August, officials said.

Photo: mohammed benmansour/Reuters

At Bear Hugs Preschool in the Red Sea coastal city of Jeddah, kindergarten students ran to greet their teachers and friends and later attended a magic show and pony ride. Adding to the celebratory air, some parents brought doughnut boxes.

Shagufa Afshan, 39 years old, brought a homemade cake for her 5-year-old son that read: “Back to school, Hashim.”

“I am more excited than my son,” said Ms. Afshan, a stay-at-home mother of five who believes her son’s language and social development was stunted during the pandemic. “It was a nightmare having all these kids at home.”

Saudi Arabia’s approach to classroom learning during the pandemic was among the most cautious in the world. While children aged 12 years and older were allowed back into class in August, the kingdom held back on a return for those aged 5 to 11, with the government saying it needed more time to study the risks for a group that, at the time, couldn’t be vaccinated.

The school closures were among many strict measures that Saudi Arabia, the largest Gulf state with a population of some 35 million, took during the pandemic, including a vaccine mandate for nearly all residents. Classrooms were shut in both the state-supported school system for Saudi nationals and private schools.

Bear Hugs Preschool in the Red Sea coastal city of Jeddah reopened to children on Sunday.

Photo: Bear Hugs Preschool

Saudi education officials say the school closures were recommended by health authorities and were designed to protect students and staff. The government has said surveys showed that Saudi parents overwhelmingly supported distance learning during the pandemic.

On Jan. 9, Saudi officials changed course, saying children 5 to 11 could return to classrooms by Sunday, the beginning of the workweek in Saudi Arabia.

“We cannot continue with distance learning alone,” said Ibtisam Alshehri, spokeswoman for the Saudi education ministry, in a news conference at the time.

Education officials world-wide have grappled with how to teach children during the pandemic, balancing the long-term impact of closures on young minds and working parents against the risk of spreading the virus. Studies have shown that children faced learning loss outside the physical classroom, and that they have experienced setbacks in social and emotional development.

In the U.S., where remote-learning was decided on a school district-by-district basis, nearly all students went back to some form of physical classroom in 2021. In Europe, by the end of September 2020, most schools had reopened, while across the Middle East and North Africa schools were shut for four to six weeks longer than the global average, according to Unicef.

Alya, 11, attends an online class in Jeddah.

Photo: Dina Omar

Few countries have held children out of school longer than Saudi Arabia. Uganda sent children of all grades back earlier this month, leaving Saudi elementary-school children and kindergartners among the last in the world to be learning at home.

Jane Ruiz, a teacher at Bear Hugs Preschool, said one of the main challenges she faced with online learning was assessing the students and their progress. “I am very happy to have the students back in class because I can now spend time with them one on one,” she said Sunday.

In a kingdom that shows little tolerance for dissent, parental anger over the school closures has been muted in public. But privately, some families have expressed anger over mothers quitting their jobs to help children learn at home and paying for tutors.

“We were paying the same tuition fees but because my husband and I work full-time jobs and we could not be home with the kids to help them, so we had to pay more to get extra help,” said Laila Ismaeel, a Saudi marketing executive in Jeddah, who splits her time between home and the office. She hired a math tutor for her 7-year-old daughter.

Osama Baghdadi, a pediatrician in Jeddah, said he was noticing more cases of young children whose anxiety and depression were causing physical ailments.

Dina Omar, a 37-year-old mother of three elementary school-age children, said she struggled with aspects of having the children home all the time, including limiting their screen time.

“They spend all day on the screen and then they want to play games or watch TV on the iPad after their classes,” Ms. Omar said of distance learning.

With the Omicron variant pushing daily infections to a record total of 5,928 last week, Saudi officials said schools are taking precautions as they return to the classroom, distributing masks and hand sanitizer and enforcing social distancing. Students will mix as little as possible. Morning student assembly is canceled, and recess time and common areas are split up by class.

Online education platforms will continue for those with critical health conditions that prevent them from attending face-to-face classes.

The kingdom didn’t see a rise in cases when middle and high schools reopened in August, and students were required to receive both doses of the Covid-19 vaccine, officials said. However, 5-to-11-year-olds haven’t been required to get the vaccine in Saudi Arabia.

Abeer Al-hamrani, 47, a stay-at-home mother to twin 5-year-old boys, says her biggest worry is that the children are too young to fully grasp the seriousness of the pandemic and that it will be hard for them to comply with safety measures. She wants her children to return to school, but she said she is also nervous.

“I am overwhelmed and anxious,” she said. “I’m also worried that other parents will be reckless and send their children sick.”

Write to Summer Said at summer.said@wsj.com