One afternoon last November, the WikiLeaks founder Julian Assange collected his lawyer and entered the office of Alan Rusbridger, editor of The Guardian newspaper.

He had every reason to be pleased: within days the name of his website would be spewing from every media outlet and his reputation as the world's leading "freedom of information warrior" would be confirmed.

But the visit was not a happy one. Assange had come to threaten the newspaper with legal action if it went ahead with plans to run stories based on the vast quantity of US government material leaked to his website.

The relationship between Assange and the newspaper had by this point descended into one that involved "distrust and anger", becoming so acrimonious that the WikiLeaks founder claimed it had breached an agreement on the publication of the data which he saw as his own.

In a detailed account of the tensions, Vanity Fair magazine reports that Assange argued that "he owned the information and had a financial interest in how and when it was released".

The article claims that Nick Davies, one of the Guardian journalists who forged the relationship with Assange, has not spoken to the Australian for more than five months after a bitter falling out. Assange reportedly angered Davies by involving Channel 4 in the WikiLeaks coverage. The collaborative reporting project, which involved a global network of media organisations, was "marked by serial delays and considerable mistrust on all sides", says Vanity Fair, quoting one senior journalist complaining that "everyone's a cheat".

Assange, a former computer hacker, is under police bail in Britain, facing extradition to Sweden for questioning over allegations of sexual assault. His WikiLeaks website became internationally famous with its disclosure early last year of official US documents about the conduct of the Iraq War, most notably a video of an Apache helicopter opening fire on a van that included a Reuters photographer and his driver. The incident resulted in the deaths of 12 innocent people and the online video, which was dubbed "Collateral Murder", became a viral sensation.

Then WikiLeaks received a new batch of documents, containing a treasure trove of 400,000 pages of confidential information detailing seven years of US operations in Afghanistan, along with a further cache containing highly sensitive American diplomatic cables. They amounted to what Vanity Fair described as "one of the greatest journalistic scoops of the last 30 years".

Assange chose The New York Times as one of his media partners, along with The Guardian and the German news magazine Der Spiegel. But of his partnership with the British newspaper, Vanity Fair said it "brought together two desperately ambitious organisations that happen to be diametric opposites in their approach to reporting the news". The Guardian's David Leigh told the magazine: "We were starting from: 'Here's a document. How much of it shall we print?' Whereas Julian's ideology was: 'I shall dump everything out and then you have to try and persuade me to cross a few things out.' We were coming at it from opposite poles."

Vanity Fair reports that The Guardian was covering the story while under severe financial pressure, with annual losses of £37.9m.

Assange had his own financial difficulties and, as he slept on the sofas of his supporters, he was struggling to identify a way of paying for the growing cost of his increasingly labour-intensive website.

Things came to a head in November with the angry threat of legal action. Assange had been given a letter by Rusbridger promising not to use material from "batch three" of the documents (the diplomatic cables) without the say so of WikiLeaks. But The Guardian managed to obtain the "batch three" documents through a separate source, after they were passed to a freelance journalist by a disgruntled former colleague of Assange's. WikiLeaks had itself sprung a leak. Regarding itself as free of its arrangement with Assange, The Guardian shared the material with The New York Times and Der Spiegel and prepared to publish without waiting for permission from Assange. When the Australian discovered the plan, he threatened to sue.

Mr Rusbridger managed to placate Assange, but on 18 December, the relationship plummeted again as the paper ran a front page story claiming, "Julian Assange furore deepens as new details emerge of sex crime allegations". The Australian was deeply hurt that the paper – where he had spent long hours in its building and shared meals with its staff – had turned on him.

In April the WikiLeaks founder will have his own say on his fraught relationship with The Guardian when he publishes his memoirs. There may be more friction to come.

Belfast Telegraph