GAYS and lesbians in many parts of the world are celebrating. Fifteen countries allow homosexual couples to tie the knot, and in Britain a same-sex marriages bill will become law next year. Fifteen states in America have said “I do” to gay marriage. But elsewhere the picture is less rosy. Homosexuality is a crime in more than 75 countries, which threaten sentences ranging from fines to the death penalty. Because of this and abuse by their fellow citizens, every year thousands of gays and lesbians apply for asylum in more tolerant countries, citing fear of persecution. When and where is being gay grounds for asylum? Many anti-gay laws are a hangover of the British empire. In 1533 the English parliament passed “An Acte for the punysshement of the vice of Buggerie”, the punysshement in question being death. Whereas gay sex has been legal in France since the late 18th century, it was banned in England until 1967. This helps explain why so many former British colonies in Africa still have anti-gay laws, while so few of the old French colonies do. It’s not always the fault of the Victorians, however: in some other countries, notably Russia, things have taken a recent turn for the worse.

The rules on asylum vary considerably. Italy automatically gives refuge to those from a country with anti-gay laws, while Spain makes it a lot harder. Many applications have been denied by countries that argued that gays can go home and avoid abuse simply by concealing their sexuality. America, Britain and a few others have stopped making this argument, but some European countries have continued to use the “be more discreet” defence. No longer. Earlier this month the European Court of Justice ruled that gays count as a “social group”, meaning they are eligible for asylum if they can demonstrate persecution (defined as the enforcement of prison sentences—mere fines or sporadic application of the law may not count). The verdict followed a similar ruling last year that religious refugees could not be asked to hide their faith or abstain from worship to avoid abuse back home.

But how can asylum seekers prove they are gay? Many authorities rely on absurd stereotypes to reject asylum claims: in Britain, for instance, gay applicants have been quizzed on their taste in music, according to Livio Zilli of the International Commission of Jurists, a human-rights lobby. Some applicants have gone to extreme lengths to prove their sexuality, including filming themselves in the bedroom. Sorting real from fake claims presents countries with a problem. They must solve it swiftly: because of the court ruling, the number of applications may well increase.