Facebook is to publish comprehensive data on political advertising during Ireland’s abortion referendum campaign, giving an unprecedented insight into targeting of voters on social media, and setting a powerful precedent for election transparency.

The US company has told Irish politicians it will provide anonymised details of the amount spent on targeting Irish voters on its platform between 1 March and 25 May, and the number of referendum-linked ads that had been purchased.

It will also provide details of proposed advertisements, and proposed spending, that it had rejected after bringing in a ban on foreign organisations paying for online campaigns inside Ireland.

The Irish Green party leader, Eamon Ryan, who has been pushing for greater transparency and new legislation to regulate online political campaigning, welcomed the social media firm’s decision. He said he hoped it would set a new benchmark for democracy in the internet era.

“Providing data about online spending in the recent Irish abortion referendum sets an important precedent, which should apply now in every future vote,” Ryan said.

“We want transparency about online political advertising so hidden funding does not distort the democratic process. What took place during the Brexit referendum and the last US presidential election cannot be ignored or allowed to happen again.”

He is calling for Google to follow the example set by Facebook and provide details of advertising spending across its platforms including its search engine and on the video-sharing site YouTube.

The Irish vote threw concerns about “dark ads” – targeted at individual voters or small groups, and not visible to the rest of the electorate – into sharp focus after it emerged that foreign organisations had been taking advantage of a loophole in Irish law to target voters online.

Political parties and registered campaigns are barred from taking foreign money but the legislation dating from before the internet does not cover money spent directly on digital advertising.

Ireland’s referendum drew worldwide attention from campaigners, particularly opponents of abortion, because its 8th amendment enshrined a near-total ban on the termination of pregnancies.

It was the only western democracy with such strict rules so its decision was expected to have a global impact. Irish voters delivered a landslide in favour of legalising abortion.

Under pressure from Irish politicians and activists, including the non-partisan Transparent Referendum Institute, Google banned all referendum-linked advertising on its sites.

Campaigners in Dublin celebrate the result of the Irish abortion referendum. Photograph: Charles McQuillan/Getty Images

Facebook banned all political advertising by foreign groups and rolled out a set of tools to increase advertising transparency ahead of its original schedule.

They allowed any user in Ireland to see all the ads any Facebook page was running at the time, and for a brief period to check the location of people managing campaign pages.



However, campaigners warned that the system provided only a snapshot of ads run at any given time, and they have been pushing for a more comprehensive solution.

In a letter to Ryan, the Facebook said it was ready to work with academics in Ireland to identify pages campaigning about the referendum, and then provide comprehensive details on their spending and advertisements.

Facebook warned that the data would not be 100% complete because “our systems are currently configured in such a way that makes retrieving this kind of data either straightforward or completely foolproof”.

However, managers are confident they can capture “the vast majority” of advertising activity, and the data would be “indicative of the scale of online campaign activity that took place on Facebook”, the letter says.