Jeremy Corbyn has denounced a legal bid to block him from standing in the Labour leadership election in the UK as "a waste of time and resources" after it was rejected by a High Court judge.
The ruling allows the contest between Mr Corbyn and challenger Owen Smith to continue as planned, with the result due on September 24 following a postal ballot of members, affiliates and registered supporters.
Labour donor Michael Foster failed in his attempt to overturn the Labour Party's decision to guarantee Mr Corbyn a place on the ballot paper for the election.
He claimed the Labour Party's rules were "misapplied" when its national executive committee (NEC) voted by a majority of 18 to 14 that Mr Corbyn should have an automatic place without needing to obtain the backing of 20% of Labour MPs and MEPs - 51 nominations.
Mr Corbyn was not at London's High Court on Thursday when Mr Justice Foskett dismissed Mr Foster's claim.
The Labour leader said in a statement: "I welcome the decision by the High Court to respect the democracy of the Labour Party.
"This has been a waste of time and resources when our party should be focused on holding the Government to account.
"There should have been no question of the right of half a million Labour Party members to choose their own leader being overturned. If anything, the aim should be to expand the number of voters in this election.
"I hope all candidates and supporters will reject any attempt to prolong this process, and that we can now proceed with the election in a comradely and respectful manner."
Mr Foster brought the case against the party's general secretary, Iain McNicol, who was sued in a representative capacity, as well as Mr Corbyn.
Following the court's decision, Mr McNicol said: "We are delighted that the court has upheld the authority and decision of the National Executive Committee of the Labour Party.
"We will continue with the leadership election as agreed by the NEC."
Mr Smith said: "I'm pleased the court has done the right thing and ruled that Jeremy should be on the ballot. This now puts to bed any questions about the process, so we can get on with discussing the issues that really matter.
"I'm getting on with the job of talking to Labour members and supporters, and am looking forward to debating with Jeremy as often as possible about our plans for Labour's future.
"I will take every opportunity to set out my ideas for a radical Labour Party that can replace failed Tory austerity with a plan for prosperity."
Labour's rulebook states that "potential challengers" in a leadership contest are required to gather nominations, but does not explicitly say whether this rule also applies to the incumbent leader.
After losing a vote of no confidence among his own MPs by 172-40, there were real doubts over whether Mr Corbyn - the clear favourite to be re-elected in September, a year after winning the leadership by a landslide - would be able to stand.
If the judgment had gone against Mr Corbyn, Labour would have had to re-run the nomination process, potentially leading to a contest in which the incumbent leader could not defend his position.
Mr Foster's QC, Gavin Millar, argued that the NEC's interpretation of the rule at its July 12 meeting was not "reasonable".
But Mark Henderson, counsel for Mr McNicol, said the rules were not ambiguous or open to serious doubt and Martin Westgate QC, for Mr Corbyn, argued that the NEC's conclusion was "plainly right".
He said: "In any case, the conclusion reached by the NEC is entitled to great respect and the court should not interfere with it."
In his ruling, the judge said the NEC had reached the correct legal conclusion and "were right to conclude that Mr Corbyn was entitled to be on the ballot paper without the need to obtain any level of nominations".
He said that views on the ruling would doubtless reflect "the well-publicised divisions that exist within the Labour Party", but insisted his decision was "wholly uninfluenced by which side will be pleased with the outcome".
It had been suggested that those responsible for drafting the rules might not have foreseen a situation where a sitting leader was unable to muster the required nominations, said the judge.
He added: "It is not for me to speculate, but if he is right, it is not for the court to try to re-write the rules to provide a solution. The responsibility for that lies elsewhere."
Mr Foster did not apply for permission to appeal. Mr Millar said that, in bringing the case, the Labour donor was not seeking anything other than a proper application of the rules.
"The claimant has no wish to deny the second defendant (Mr Corbyn) a fair opportunity, which can be achieved in this way, of obtaining the requisite number of nominations," he said
But Mr Westgate said this stance failed to recognise the disruption it would inevitably cause.
Ballot papers will start to be sent out on August 22, with the result announced at a special conference in Liverpool on September 24.
Mr Smith, who quit Mr Corbyn's shadow cabinet along with many colleagues last month, easily cleared the 51-nomination hurdle, securing the support of 162 Labour MPs - 70% of the party's representation in the Commons - as well as 10 MEPs.
He became the sole contender to replace Mr Corbyn when Angela Eagle withdrew her candidacy earlier this month.