The Court of Appeal has stated that 'married couples only' policies on double rooms at bed & breakfasts should not be considered "direct discrimination".
The ruling was in relation to Susanne Wilkinson and her family-run B&B, near Cookham in Berkshire.
Mrs Wilkinson was sued by a gay couple, Michael Black and John Morgan, after they were told they could not have a double bed in March 2010.
Mrs Wilkinson said she was seeking to uphold her beliefs about marriage but in October last year, a county court ruled that her policy directly discriminated against gay couples and she was ordered to pay £3,600 in damages.
The Court of Appeal this week upheld the county court's ruling although Master of the Rolls, Lord Dyson said he was "reluctant" to do so and would prefer to treat a 'married couples only' policy as indirect discrimination.
Indirect discrimination means that such a policy can be lawful if it is justified.
The appeals court ruling also stated that religious rights were of equal importance to sexual orientation rights.
The Christian Institute, which funded Mrs Wilkinson's appeal, welcomed the ruling as a "step in the right direction" for people wishing to act according to their beliefs about marriage and for B&Bs with 'married couples only' policies.
Spokesman Mike Judge said: "I'm disappointed for Susanne that she didn't succeed on this occasion, but I am pleased that the court has taken a step in the right direction.
"For the first time in cases like these, the court has properly engaged in arguments of justification, and attempted to balance religious rights and sexual orientation rights.
"Balance is the key word. There should be more even-handedness for Christians who hold traditional views about marriage."
Although the Court of Appeal said a 'married couples only' policy could be justified, it concluded that this was not the case with Mrs Wilkinson's as she could have converted her B&B to single bed accommodation without it having a fatal economic impact on her.
A similar case involving another B&B, owned by Peter and Hazelmary Bull from Cornwall, is due to be heard by the Supreme Court later this year.
If permission is granted for Mrs Wilkinson to appeal, her case could be joined with the Bulls so that the Supreme Court can hear both cases together.
Mrs Wilkinson said she was disappointed with the Court of Appeal's ruling but pleased that there was "hope" for people with similar marriage beliefs.
"I am also disappointed with the judges' weighing up of the specific facts of the case and their bearing on indirect discrimination. In particular their justification that a change on my part whereby I would limit double rooms to single occupancy would not necessarily be economically fatal," she said.
"This economic justification does not place sufficient weight on the principle involved by which I seek to conscientiously operate my business according to biblical values.
"Surely in our diverse 21st century UK society there is ample room for a variety of lifestyles with many thousands of other B&Bs being willing to accommodate unmarried couples.
"It's sad that cases like this are coming to court in a country that has a great Christian heritage. However, whatever the outcome of my case, my faith is grounded in a sovereign, loving and unchanging God and his eternal plans and purposes."