Connolly, 68, a long-time critic of the European Union in overwhelmingly pro-EU Ireland backed by the left-dominated opposition, was not a household name and was underestimated by many at the start of the contest for the largely ceremonial role.
Connolly, an independent candidate, built momentum as the campaign progressed, enthused younger voters and was elected with 63.4 per cent of the vote.
The other candidate seeking election, ex-cabinet minister Heather Humphreys of Fine Gael, won 29.5 per cent.
Jim Gavin, a candidate from Fianna Fail party who quit the race three weeks before the election but whose name remained on the ballot paper, received 7.2 per cent.
"I will be a president who listens, who reflects and who speaks when it's necessary. Together we can shape a new republic that values everybody," Connolly said in a speech at Dublin Castle.
Ireland's president is largely a figurehead, with seldom-used powers to test the constitutionality of legislation, but often speaks on the global stage and welcomes other heads of state to the country.
Many of Connolly's views - from denouncing the EU's plans to boost military spending to questioning the trustworthiness of the United States, the United Kingdom and France over their stance on the war in the Gaza Strip - are well to the left of many of the parties that backedi her, as well as outspoken incumbent Michael D Higgins.
The former clinical psychologist and barrister is also one of the leading pro-Palestinian voices in parliament - a stance shared by the government and most voters.
Although Connolly served as deputy speaker of Ireland's lower house after being first elected in 2016, her win was widely viewed as continuing the recent trend of choosing a more independent president based on the candidate's values.
She also benefited from dire campaigns from the two governing parties.
Humphreys was not Fine Gael's first choice and Fianna Fail's pick, former Gaelic football coach Gavin, abandoned his bid due to a financial scandal.
The result was a boost to hopes among the previously divided left-wing opposition, led by Sinn Fein, of building a block capable of ending their centre-right rivals' century-long grip on power.
Political analysts caution that such cohesion will be more challenging when the parties are in competition in a parliamentary election due by 2030.
An Ireland Thinks polling-day survey suggested only 51 per cent of Connolly voters would vote for a left-wing alliance.
Labour Party leader Ivana Bacik said on Saturday the centre-left party would have issues with a coalition led by Sinn Fein.
A record 13 per cent of voters also spoiled their votes, partly due to a planned protest by supporters of a conservative campaigner who failed to secure the required support from elected representatives to make the ballot.
Prime Minister Micheal Martin said the government was open to reforming the nomination process.
with AP