RTÉ has apologised to businessman and former presidential candidate Seán Gallagher and paid him "substantial damages" in settlement over a tweet read out on a live televised debate during the 2011 presidential election campaign.

Mr Gallagher began legal proceedings in 2013, seeking a declaration that the RTÉ Frontline programme involving the election candidates was deliberately and unfairly edited, presented and directed by RTÉ to damage his electoral prospects.

He claimed for damages, including exemplary damages arising from comments made by broadcaster Pat Kenny.

RTÉ had denied Mr Gallagher's claims.

The Broadcasting Authority of Ireland previously upheld a complaint made by Mr Gallagher about the incident.

The tweet purported to be from an account linked to the Sinn Féin candidate in the election, Martin McGuinness.

The account was not the official McGuinness campaign account.

In April, the High Court ordered that an independent expert on electronic discovery of documents be appointed to conduct a comprehensive review of the disclosure to be made by Mr Gallagher.

The expert then provided a report to both parties. Mr Gallagher then swore affidavits of discovery which were considered by RTÉ.

In the High Court this morning, Mr Gallagher's Senior Counsel, Jim O'Callaghan, said he was pleased to tell the court that not only had the discovery issue been resolved but the entire proceedings had been resolved in their entirety.

As part of the settlement, Paul Gallagher SC, read an apology to the court on behalf of RTÉ.

In the apology RTÉ acknowledged that it made mistakes and failed to comply with its statutory duty under the Broadcasting Act during the programme broadcast on 24 October 2011.

It acknowledged that it should have verified the origin of the tweet, and the tweet should not have been erroneously attributed to another candidate's Twitter account.

RTÉ also acknowledged that it should not have broadcast the tweet and when it became apparent that it was false, it should have immediately corrected the fact that the provenance of the tweet was mistaken.

It said it failed in its obligations to Mr Gallagher.

RTÉ apologised to Mr Gallagher and acknowledged that the production of the programme fell significantly short of the standards expected by the public and required by law.

Mr Gallagher was not in court but his solicitor, Paul Tweed, read a statement on his behalf.

He welcomed the settlement and said part of the reason he had taken this action was to ensure such an incident never happened again.

Mr Tweed said RTÉ's apology had been supported by the payment of "substantial damages" although he said the terms of the settlement were confidential.

Speaking outside the court, Mr Tweed said his client was satisfied that RTÉ had acknowledged before the court of its failure to treat him with due fairness and impartiality in the preparation and broadcast of the presidential debate in 2011, which he said was being supported by the payment of substantial damages.

He said Mr Gallagher hoped that this apology and acknowledgement of the BAI findings and RTÉ's own internal report prepared by Rob Morrison and Steve Carson would lead to significant improvement in procedure and protocol for the next presidential debate in 2018.

Mr Tweed said Mr Gallagher's motivation in taking this case had not just been about addressing the unfairness shown to him but also about protecting the integrity of the democratic process and ensuring that what happened to him will not be allowed to happen again.