Southampton University is facing a large compensation bill for dismissing an overseas academic whose leave to remain in the UK had expired.
An Employment Appeals Tribunal ruling published last week said Colleen Kelly had been unfairly dismissed despite the university's belief that it would have been illegal to employ her without a visa.
Before Dr Kelly started her contract at Southampton in 2001, what was then the Department for Education and Skills had given her permission to work as a biology lecturer for 60 months. But the Immigration and Nationality Directorate issued a visa granting leave to remain for only for 48 months.
Dr Kelly, a US citizen, failed to renew her visa before it expired on January 8, 2005. She was not granted indefinite leave to remain until a month later.
In the intervening period, the university fired her after its head of legal services advised that if Dr Kelly had no right to remain in the UK, it would be breaking the law by employing her.
The lecturer received no warning of her dismissal, as the university decided that its disciplinary procedure, including any right of appeal, was inapplicable.
Judge Richardson said that the university would not have acted illegally by continuing to employ Dr Kelly, and that she had a powerful argument that her dismissal was unreasonable.
"The university had given her time to resolve the position and supported her application for indefinite leave to remain. That was a reasonable stance to take and it is arguable that to resile (withdraw) from it without warning was wholly unreasonable," he said.
Compensation will be decided by a new tribunal that will convene in the spring.
A spokeswoman for Southampton said: "An employment tribunal found that the university had acted fairly in dismissing Dr Kelly, on the grounds that it would otherwise have been committing a criminal offence in employing someone who did not have leave to remain and work in the UK. This decision has been overturned on appeal.
"The university is obviously disappointed that the appeal tribunal has come to a different decision and is considering seeking leave to appeal ... In the circumstances it would be inappropriate to comment further."
Changes to immigration law due to come into force next year mean that universities will have to be more proactive in checking employees' immigration status and ensuring that visa extension applications are processed in time.