City College of San Francisco could become free for all students under a proposal floated Tuesday by Supervisor Jane Kim.

Kim said providing free classes would allow students from all walks of life to pursue their dreams, but it may have an even more important impact: to rebuild the college’s hemorrhaging student population, which has declined by 30 percent since 2012. That’s when the college began battling to maintain its accreditation.

Kim has yet to introduce legislation related to her proposal. It is contingent on getting a measure on the November ballot to increase transfer taxes on commercial and residential buildings that sell for more than $5 million — and voters passing that measure.

“We may not be able to stop the luxury housing market here in San Francisco, but we can certainly ask those that are buying homes above $5 million and above $25 million to pay more,” Kim said at a news conference on City Hall steps Tuesday.

Two CCSF trustees, John Rizzo and Brigitte Davila, also spoke in support of the idea.

The college now has around 70,000 full- and part-time students, down from 100,000 four years ago.

At least a fifth of enrolled students already receive a fee waiver to attend classes for free. For those students, Kim wants to make them eligible for free textbooks, transportation and child care.

A key supporter of Kim’s proposal is the American Federation of Teachers Local 2121, which represents the teachers, counselors and other workers at CCSF.

“This proposal opens the door of opportunity for folks who need to rise up in our society,” said Tim Killikelly, the union’s president and a teacher at the school. “This is an idea whose time has come.”

CCSF spokesman Jeff Hamilton said the college did not have details about the proposal.

“We appreciate Supervisor Kim’s efforts. We haven’t heard the details. We look forward to discussions with Supervisor Kim to learn more about her proposal,” Hamilton said.

Also on Tuesday, the Board of Supervisors unanimously passed legislation requiring the installation of solar panels on new residential and commercial buildings.

“San Francisco is once again leading the nation in the fight against climate change and the reduction of our reliance on fossil fuels,” Supervisor Scott Wiener, who authored the legislation, said in a statement.

The new solar panels can take the form of solar photovoltaic or solar water panels.

Emily Green is a San Francisco Chronicle staff writer. Email: egreen@sfchronicle.com Twitter: @emilytgreen