Asylum seekers who arrive in the UK illegally after being rescued at sea can be prosecuted lawfully under new legal powers, the Court of Appeal has ruled.

Provisions in the Nationality and Borders Act, which came into force last year, were considered by leading judges after a hearing in London last month following appeals by three Sudanese men who are due to stand trial for immigration offences later this year.

Parts of the act were introduced to close a perceived loophole in the law which meant migrants crossing the English Channel could not be prosecuted with entry offences if they did not reach UK land by themselves.

Two of the men are alleged to have assisted unlawful immigration by steering dinghies containing other migrants across the Channel, while the third is charged with attempting to arrive in the UK in a dinghy.

They challenged preliminary rulings, made by Mr Justice Cavanagh at Canterbury Crown Court ahead of their trials, with their lawyers arguing the judge had incorrectly interpreted the new laws.

The appeals centred on whether parts of the new act have changed the law to allow the prosecution of migrants who are intercepted or rescued at sea.

Previously, migrants who were intercepted by the authorities or rescued while still at sea could not be charged with knowingly entering the UK without leave.

Lawyers representing the man charged with attempting to arrive in the UK argued that a new offence of knowingly arriving in the country without valid entry clearance could not be committed by a person intending to seek asylum, because entry clearance is not available to asylum seekers.

They said it is also not possible to make a claim for asylum from outside the UK, while an application for entry must be made from outside the country.

Lawyers for the other two men argued that, in order for an offence of facilitating the illegal entry of another person to be committed, the facilitator would have to be aware the conduct of the other person was criminal.

But, in a ruling on Thursday, the Lord Chief Justice Lord Burnett rejected the appeals and upheld Mr Justice Cavanagh’s interpretation of the new laws.

Sitting with Mr Justice Holgate and Mr Justice Bryan, he concluded the new law “applies to a person who requires entry clearance under the immigration rules and who knowingly arrives in the UK without such clearance, even if he or she intends to claim asylum on arrival”.

He added: “That is also the position in relation to an attempt to commit such an offence.”

The judge also said that, in order for a facilitation offence to be committed, the “conduct facilitated need not be criminal at all”, adding: “It need only be a breach of immigration law.”

The legislation was introduced last year in a bid to clamp down on the large number of migrants crossing the Channel in small boats.

Home Office figures suggest more than 2,000 migrants have crossed the Channel already this year.