The measure, SB 185 by state Senate leader Kevin de León (D-Los Angeles), requires the funds to sell their holdings in companies that derive at least half of their revenue from mining coal used to generate electricity.
The deadline for divestment is July 1, 2017, and new investments will be prohibited.
The new law will affect $58 million held by the
De León pitched the measure as a way to emphasize more secure, environmentally friendly investments.
"Coal is a losing bet for California retirees and it's also incredibly harmful to our health and the health of our environment," he said in a statement.
The University of California has already taken similar steps. Last month, it sold off its $200 million in investments in coal and oil sands companies.
Divestment was opposed by the Independent Petroleum Assn. of America, which argued it will hurt financially.
"Investments in fossil fuels are good for pension funds," said Matt Dempsey, a spokesman for the group.
Follow @chrismegerian for more updates from Sacramento