A transsexual woman who was banned from marrying her boyfriend because she used to be a man has won the right to wed.
Judges in Hong Kong delivered a landmark verdict after the woman had failed in two previous attempts to overturn the law in the former British colony.
She underwent a sex change years ago but could not get married because her birth certificate classed her as a man.
The government even contributed to the cost of the operation but until now marrying her lover was impossible.
Now the woman, known only as W, must wait 12 months to wear her white dress, while the law is amended.
She hailed the verdict by Hong Kong's Court of Final Appeal. "This is a victory for all women in Hong Kong," she said.
"I have lived my life as a woman and been treated as a woman in all respects except as regards to my right to marry. This decision rights that wrong.
"I'm very happy that the court of appeal now recognises my desire to marry my boyfriend one day, and that desire is no different to that of any other woman who seeks the same in Hong Kong."
The judges voted in favour by four to one. In its ruling, the court said that the issue was about more than merely genitalia.
"Viewing the realities of W's position, by denying a post-operative transsexual woman like her the right to marry a man, the statutory provisions in question deny her the right to marry at all.
"It is contrary to principle to focus merely on biological features fixed at the time of birth." The law as it stood "impairs the very essence of W's right to marry," they added.
Dissenting judge Patrick Chan claimed there was no public will to change the status quo of marriage as being exclusively between a man and a woman.
He said: "There is no evidence that the social attitudes in Hong Kong towards the traditional concept of marriage and the marriage institution have fundamentally altered."