Oxford University has rewritten the laws governing its strict academic dress code so that women may wear trousers and men may wear skirts if they so choose.
Until now, the old laws on academic clothing - known as subfusc - meant male students were required to wear a dark suit and socks, black shoes, a white bow tie and a plain white shirt and collar under their black gowns.
Female students had to wear a dark skirt or trousers, a white blouse, black tights and shoes and a black ribbon tied in a bow at the neck.
The rules have been changed following a motion put forward the university's Lesbian, Gay, Bisexual, Trans and Queer Society and passed by the student union.
The change will make a number of students' exam experience significantly less stressful, said Jess Pumphrey, LGBTQ Soc's executive officer.
"In future there will be no need for transgender students to cross-dress to avoid being confronted by invigilators or disciplined during their exam," she told the Oxford Student newspaper.
The society believes the old rules were unfair towards transgender students.
If such a student wanted to wear subfusc of the opposite sex they had to seek special dispensation from university proctors, who had the power to punish those who breached the rules.
An Oxford University spokesman said: "The regulations have been amended to remove any reference to gender, in response to concerns raised by Oxford University Student Union that the existing regulations did not serve the interests of transgender students."
Oxford's rival Cambridge University relaxed its rules some time ago.