The security guard handed over a key with a small yellow label. The Guardian’s secure room had housed the team that in 2013 worked through data leaked by Edward Snowden to expose unchecked surveillance by British and American spy agencies.  Now it was to be home to a small group of journalists gathered from all corners of the newsroom to work on a project code-named Prometheus. Our investigation into the murky world of tax havens, underpinned by the biggest leak in history, would eventually surface eight months later with the publication of the Panama Papers.  The story began back in February 2015, with an article in Süddeutsche Zeitung that revealed the German newspaper had a slug of secret files about offshore companies on the books of the Panamanian law firm Mossack Fonseca. Some 80 gigabytes of data about the firm’s customers had been received by the paper’s investigative reporters, Bastian Obermayer and Frederik Obermaier.  Related: What are the Panama Papers? A guide to history's biggest data leak  A source would go on to leak 2.6 terabytes of information, sending the pair as an opening message: “Hello, this is John Doe. Interested in data?” The source demanded absolute anonymity. To this day, his or her identity remains unknown to the Panama Papers reporters. “My life is in danger, we will only chat over encrypted files. No meeting ever.”  The Guardian’s involvement formally began in September 2015, when Katharine Viner, the paper’s editor-in-chief, and Paul Johnson, deputy editor, flew to Munich to secure participation in the consortium of journalists around the world collaborating on the story.  Back in London, the team began poring over the archives of Mossack Fonseca. These were being gradually uploaded to servers managed by the International Consortium of Investigative Journalists (ICIJ) in Washington. The database would eventually include 11.5m emails, passport scans, contracts, share registers and even sound recordings.  As a business reporter tasked with unpicking the tax-sheltering schemes used by California technology groups and London property developers, I have followed many trails leading to offshore dead ends. The Panama Papers meant that for the first time I was able to take a good, long look at what lay beyond the wall of secrecy.  It quickly became apparent that offshore agents such as Mossack Fonseca often have no special knowledge about their customers. Tax havens’ lack of transparency may allow the keeping of secrets, but these secrets are often kept elsewhere.  As a result, the database needed to be approached from multiple angles, whacked with many sticks, until it could be cracked.  The Guardian brought together its specialists. Luke Harding, the paper’s foremost Russia expert, took on the huge task of investigating Mossack Fonseca’s many Russian and Ukrainian customers. Simon Bowers, a tax and fraud specialist from the City desk, picked apart the undeclared offshore holdings of Iceland’s prime minister.  Holly Watt, who had previously exposed the MPs’ expenses scandal for the Daily Telegraph, tracked down the files relating to members of parliament, peers and political donors. The Guardian’s chief sports writer, Owen Gibson, delved into the world of sport, while reporters in the paper’s New York and Sydney offices hunted for stories of local interest.  David Pegg, with whom I had worked on the HSBC files, exposing tax evasion at the Swiss branch of Britain’s biggest bank, matched land registry records with lists of Mossack Fonseca companies. He soon realised that the firm was acting for roughly 10% of all offshore companies with land holdings in Britain.  Helena Bengtsson, editor of the data projects team at the Guardian, compiled lists of the names of everyone from members of parliament to those wanted by Interpol or on European or US sanctions orders. She then cross-matched these with the Panama Papers data, checking tens of thousands of names at a time and leaving her computer running all night so she could comb through the results in the morning.  We worked hard to keep the information safe. With investigative reporters looking into a $2bn Russian money-laundering scheme linked to Vladimir Putin, the threat of a hack by the FSB, Russia’s security agency, was very real.  More than 140 high-ranking politicians and heads of state were uncovered in the data, leaving partners in less democratic countries at risk of government retaliation. Since the Panama Papers were published Ecuador’s president, Rafael Correa, has used Twitter to name and admonish local journalists for not handing over all the data. In Venezuela, the journalist Ahiana Figueroa has been fired from her news organisation for being part of the Panama Papers team. In Tunisia, the website Inkyfada has come under suspected cyber attack after naming a former presidential adviser.  The five reporters in the core team spent long days over the winter interrogating the data, plugged into headphones and staring at screens.  As we worked, more information was being leaked. New data was uploaded at regular intervals, with the last set dating from December 2015. In February, we began to approach those we intended to name, and our research began to collide with events in the outside world. In places far away from Britain, the impact of the Panama Papers was beginning to be felt in local and apparently isolated political scandals.  In late January, two Mossack Fonseca representatives in Brazil were arrested, and later released, by authorities investigating the Petrobras affair. Two others fled the country. A prosecutor in the case described the firm as a “money-washing machine”.  On 4 March, the law firm received a letter from the ICIJ and Süddeutsche Zeitung stating that they had seen information concerning thousands of its companies.  On 11 March, TV crews from the consortium descended on Panama City to film the firm’s offices and ask for interviews. Later that day, founding partner Ramón Fonseca resigned from his position as an official adviser to the Panamanian president, Juan Carlos Varela. In a parting shot, he tweeted: “The pen is a powerful tool. It’s sad when used for evil.”  On the same day, the Icelandic prime minister, Sigmundur Davíð Gunnlaugsson, walked out of a television interview with two Panama Papers reporters, the independent documentary maker Jóhannes Kristjánsson and Sven Bergman from Swedish TV. They had, on camera, named Wintris, the undeclared offshore company he had once owned with his wife, and which his wife still owned.  The film would not be released until 7pm GMT on Sunday 3 April, the date that all 110 news outlets brought together by the ICIJ had agreed to release their stories simultaneously.  But by the Monday before publication, the Kremlin was beginning to spin. Putin’s spokesman held a press conference to warn that a number of journalists were planning an “information attack” on the Russian president, led by the ICIJ. Key names, including those of the banker Yuri Kovalchuk and the cellist Sergei Roldugin, were released.  The atmosphere inside the secure room at the Guardian was tense. We had by now been joined by the paper’s investigations head, Nick Hopkins, picture researchers and a crack team of subeditors who moulded a mass of 33 articles into publishable form.  Would the story hold? Should we bring the publication date forward? Requests for information began to flood into the ICIJ. Like a general holding back his troops before the charge, the consortium’s director, Gerard Ryle, hit the phones, talking editors into holding their nerve.  By the Friday, two days before we published, there were calls for a vote of no confidence in the Icelandic parliament. But the key data relating to Gunnlaugsson’s offshore adventure remained unpublished, and so the embargo agreed months beforehand stayed in place.  After months working on our own, on Sunday 3 April, the Panama Papers reporting team emerged from the locked office to gather around a desk in the centre of the newsroom. There were 11 items ready to be published. Viner and Johnson stood ready to give the signal.  At 6.48pm, Edward Snowden sent a Twitter message to his 2 million followers: “The biggest leak in the history of data journalism just went live, and it’s about corruption.” His tweet linked to a Süddeutsche Zeitung article headlined A Storm is Coming.  Within minutes, the Panama Papers whirlwind had struck. In 70 countries around the world, the reverberations are still being felt.  Süddeutsche Zeitung reveals in print that it has been handed leaked files from the internal database of Mossack Fonseca. Over the coming months, 2.6 terabytes of internal company data will be handed over to the reporters by a source calling themselves John Doe. The information is near live.  Forty journalists from a dozen news organisations including Le Monde, the Guardian and the BBC are invited to the International Consortium of Investigative Journalists in Washington to discuss collaboration.  Katharine Viner, editor-in-chief, and Paul Johnson, deputy editor, fly to Munich to secure the Guardian’s participation in the consortium of journalists investigating the story.  The sheer size and complexity of the $2bn Russian money-laundering operation surrounding Vladimir Putin’s close friends has begun to emerge. The Guardian hosts a two-day summit attended by reporters from France, Germany, Switzerland and Washington to dissect the details.  Two Mossack Fonseca representatives are arrested in Brazil, in connection with the Petrobras scandal. They are later released, while two others flee the country. From this moment, the risk is high that elements of the Panama Papers investigations will leak before the scheduled publication day.  Mossack Fonseca is told in a letter from the ICIJ and Süddeutsche Zeitung that they have seen information concerning thousands of the companies it has incorporated.  The Icelandic prime minister walks out of a television interview. The footage will be kept under wraps until publication day.  Mossack Fonseca’s office in Panama is surrounded by television crews, all preparing Panama Papers documentaries. Founding partner Ramón Fonseca resigns from his position as an official adviser to the Panamanian president, Juan Carlos Varela.  Anna Pálsdóttir, Gunnlaugsson’s wife, makes what appears to be an unprompted declaration about her offshore company, Wintris, on her Facebook page in which she claims her husband had only held shares because of an administrative error.  The Kremlin warns Russian media that it has received a letter from a number of journalists who are planning an “information attack” on Vladimir Putin, led by the ICIJ.  Edward Snowden tweets a link to a Süddeutsche Zeitung article headlined A Storm is Coming.  7pm GMT, Sunday 3 April  The opening stories of the Panama Papers are published simultaneously around the world. The partners range from the BBC and Le Monde to the Korea Center for Investigative Journalism and the French-language online newspaper Inkyfada in Tunisia.  • Join us on Monday 18 April for a Guardian Members event exploring the fallout from the Panama Papers. The event, held at our London newsroom, will begin at 7pm and feature a panel including the deputy editor, Paul Johnson, head of investigations Nick Hopkins, investigations correspondent Holly Watt and foreign correspondent Luke Harding. Tickets, costing £12, can be booked here.
For six months, a team of Guardian journalists worked in tight secrecy on the biggest leak in history. This is the inside story of how the Panama Papers unfolded