Edinburgh University is to fully divest from three of the world's biggest fossil fuel producers within the next six months.
The decision has been taken by the university's investment committee, which met earlier.
It follows the end of a 10-day student occupation of one of its buildings in Chambers Street.
Campaigners said it was a "big step forward" and represented a "significant shift" in the university's position.
Professor Charlie Jeffery, the university's senior vice-principal, said: "This decision underlines the recent commitment made by the University to address the challenge of climate change though its responsible investment policy.
"We will act quickly to reduce harmful emissions through divestment, reinforcing the work we do to act on climate change through research and teaching."
Kirsty Haigh, student campaigner with Edinburgh People and Planet and NUS Scotland VP Communities, said: "We are glad to see the University finally accept that there are lower carbon alternatives to coal and tar sands, but it should have never taken this long.
"The University is pledging to 'engage' with these companies for the next four weeks before divesting, but has refused to outline what that means.
"These companies pour millions into greenwashing and it is crucial that the University is not bought over by this, and that they follow through and fully divest from them."
Lang Banks, WWF Scotland director, said: "This is a welcome move by the University and we hope it marks the beginning of the end for their investments in climate-trashing fossil fuels.
"The students and staff are to be congratulated for their persistence on this important global issue, as I am in no doubt this would not have happened had it not been for their campaign.
"The science is clear, to protect our climate the vast majority of known fossil fuel reserves must remain unburned and in the ground."
Ric Lander, of Friends of the Earth Scotland, said: "To avoid catastrophic climate change we know that 80% of fossil fuels reserves must be kept in the ground. The investment decisions of Scottish institutions will play a part in shaping our future and they must be held accountable for the impacts of their investment policy.
"Today's announcement suggests Edinburgh University is listening but students, staff and alumni are unlikely to be reassured until they take the final step to divest from fossil fuel companies.
"Coal and tar sands cause enormous environmental destruction wherever they are extracted and are incompatible with a low-carbon future. We urgently need a transformation of our energy system to clean, reliable renewables."