“This is important to us because climate change is supposed to be a huge problem and so far our existing institutions have been unable to address it in a way that is commensurate with the problem,” said Alice Cherry, a second year law student and one of the seven bringing the suit. “We think it is past time for our legal system to have something to say about it.”

The lawsuit argues that Harvard, by continuing to invest in fossil fuels, is putting current and future generations in danger.

“Such investments contribute to current and future damage to the University’s reputation and to that of its students and graduates, to the ability of students to study and thrive free from the threat of catastrophic climate change, and to future damage to the university’s physical campus as a result of sea-level rise and increased storm activity,” the complaint contends.

The students are calling for Harvard to withdraw immediately from an estimated $79m in direct investments in coal, oil and gas companies, and begin phasing out all other investments containing fossil fuel stocks.

Last week, 34 Harvard students staged a sit-in outside the offices of the university president, Drew Gilpin Faust. More than 230 faculty members have signed a letter calling on Harvard to drop oil and coal companies.

So far, Harvard hasn’t budged on its refusal to divest. In 2013, when Harvard was first confronted with divestment demands, Faust responded that the endowment was set up to support academic aims, and not serve other purposes.

The university said its lawyers would urge the judge to dismiss the lawsuit.

“Climate change poses a serious threat to our planet. Harvard agrees that this threat must be confronted, but we have focused our efforts on supporting the research and teaching that will ultimately create the solutions to this challenge,” Jeff Neal, a university spokesman, said in an email.

The email accused last week’s sit-in protesters of coercion, and said they had crossed the line into unacceptable forms of protest.

“We are deeply disappointed that divestment advocates have chosen to resort to a disruptive building occupation as a means to advance their view. Such tactics cross the line from persuasion to disrespectful and coercive interference with the activities of others.”