Babar has been imprisoned without trial for seven years on trumped up terror charges.
Mr Justice Singh ruled that the BBC had the right to film and broadcast an interview with Babar.
Justice secretary Kenneth Clarke had tried to block it.
Babar’s father Ashfaq Ahmad welcomed the ruling.
“I’m pleased the high court has ruled that there is an exceptional public interest in Babar’s case,” he said.
Socialist Worker was the first newspaper to highlight Babar Ahmad’s case.
He was arrested in 2003 and badly beaten up by Metropolitan Police officers. In 2009 he won £60,000 after the Met admitted to “grave abuse tantamount to torture”.
Babar was arrested again in 2004 when the US issued a warrant for his extradition. He has been locked up ever since.
Britain’s extradition arrangements with the US were redrafted in 2003. They allow the US to extradite British citizens without providing evidence, even when they have not broken any laws in this country.