The Archdiocese of San Francisco announced the closure of all its schools after a student tested positive for the coronavirus.

The 90 schools in San Francisco, San Mateo and Marin counties will shut down Mar. 12 through Mar. 25, said Pamela Lyons, superintendent of schools in a letter to families Tuesday.

The announcement did not identify the school the student attends, but the principal of Riordan High School in San Francisco confirmed that a student there tested positive for the virus Sunday.

The all-boys high school had already announced a two-week closure on Sunday. At the time, officials said a student’s parent had tested positive.

Schools across the region have struggled with the decision over whether to close or not.

Lyons said all buildings will be closed and any planned school events, including fundraisers and field trips, would also be postponed or canceled.

“I understand the hardship this may cause for families,” Lyons said. “We made this decision out of maximum consideration for the health and safety of our children and school community members.”

Instruction would continue through distance learning, she added.

Lyons called on the community to pray for the sick, health care providers and officials as well as city leaders.

“Additional diagnoses of COVID-19 across our schools are likely,” she said.

Jill Tucker is a San Francisco Chronicle staff writer. Email: jtucker@sfchronicle.com Twitter: @jilltucker