Genuine couples are being prevented from getting married and are subjected to “insulting” and “gruelling” checks as part of a government crackdown on sham marriages, a Guardian investigation has found.

Couples and lawyers described wedding ceremonies being interrupted so that the Home Office could question people about their sex lives, an official finding a nude picture on a person’s phone and showing it to others in the room, and dawn raids carried out to check if couples were sharing a bed.

In one case, a couple were told their relationship could not be genuine because they were wearing pyjamas in bed. In others, people have been detained for months after being wrongly accused of entering into a sham marriage.

In recent years the government has made it more difficult for migrants to wed in the UK, in an effort to stop people using marriage to UK or EU citizens as a means to remain in the country.

Since changes to the law in 2015, registrars have been required to report to the Home Office whenever most categories of migrants give notice of marriage. The Home Office was given powers to delay nuptials for up to 70 days to allow for investigations.

Information obtained by the Guardian through a freedom of information request shows registrars sent 2,868 section 24 reports – which alert the authorities to a potential sham marriage – in 2018, a 40% rise from 2,038 in 2014. Lawyers said registrars had become “infected with the culture of the hostile environment”.

Of those reports last year, 1,618 (56%) were deemed worthy of investigation, compared with 1,439 (58%) in 2015. The Home Office refused to share data on the number of marriages found to be shams.

Nath Gbikpi, of Wesley Gryk Solicitors, said the government’s approach to migrant marriages needed to be seen as part of its hostile environment policy. “The Home Office has put itself in a position where it can prevent a genuine couple, whom they agree to be in a genuine relationship, to get married,” she said.

One couple, Qasim, 29, from Pakistan, and Debora, 33, from Portugal, were asleep at home when they were raided by four officials in January 2016. “We were questioned separately about our relationship and then Qasim was arrested, taken away and locked up in detention for four months before the Home Office finally accepted that our relationship was genuine,” Debora said.

“I was in a state of shock and trauma all the time I was in detention,” said Qasim. “It was very insulting that the Home Office came inside our home to check that everything was joined.”

Another couple who sought permission to marry were told their relationship would not be investigated, only to have their wedding ceremony interrupted by officials, according to a statement submitted to their lawyers and provided to the Guardian.

The statement said the couple were taken into separate rooms and asked about their sex lives, including details about sexual positions and contraception. The woman was so distressed that partway through the interview she refused to answer any more questions. The Home Office officials then halted the ceremony and declared the marriage to be sham.

The couple, who are still together, were so humiliated that they did not tell their reception guests that the marriage had not been permitted to go ahead, instead continuing with the event and pretending to celebrate.

In another case, a gay couple were invited to a Home Office reporting centre for an interview after they requested permission to enter into a civil partnership. The couple were questioned separately, the British man for 90 minutes and his Thai partner for five hours.

The Home Office asked to inspect the couple’s phones and found an email sent by the Thai man many years before to a former partner, which included a naked photo of himself. This photo was shown to everyone in the interview room, leaving the man feeling humiliated, the couple said.

“He described the whole experience as disgusting,” the British man said. “They grilled him in a very aggressive way that he found very shocking.” The immigration case was finally concluded a few months ago in the couple’s favour.

The Home Office declined to comment on individual cases.

Poppy Firmin, a caseworker at Duncan Lewis Solicitors, said: “Many people go through the asylum process unrepresented. In the meantime you can’t work, you often can’t study, and then you may or may not be permitted to marry. Or you may be detained after your marriage ceremony is gatecrashed by Home Office officials. It’s very degrading.”

Elizabeth Ruddick, of Wilsons Solicitors, said: “Home Office officials may come to your home early in the morning and check up on the number of toothbrushes … The Home Office has the right to interfere every step of the way, and some registrars have become infected with the culture of the hostile environment.”

A Home Office spokesperson said the government was focused on ensuring that family migration was based on a genuine relationship. “Registrars are given comprehensive evidence-based guidance on circumstances that may raise suspicions about a marriage, such as certain behaviours and the level of information one party knows about another,” the spokesperson said. “It would then be for Home Office immigration officials to decide whether or not to investigate further.”