Join the Connacht Rugby WhatsApp channel
Stay up to date with the latest news
Connacht 22 Leinster 24
Connacht suffered final play heartbreak as they went down to their first defeat at the Galway Sportsground since December of last year.
It looked as though they had turned things around when they fought back from trailing 19-8 to lead through final quarter tries from scrum-half Caolin Blade and wing Diarmuid Kilgallen.
But then, with the game in stoppage time, Leinster had one last throw of the dice and grabbed their chance as full-back Ciaran Frawley cut inside to score the winning try.
It will be a bitter pill for Connacht to swallow after they had battled so hard to get their noses back in front at a packed Sportsground.
Making his first appearance since the World Cup, fit-again Ireland star Mack Hansen appeared to have settled the outcome when he created the try for fellow wing Kilgallen ten minutes from time, but it wasn't to be.
The hosts had been forced into an early change when full-back Tiernan O’Halloran picked up a leg injury, which meant David Hawshaw coming off the bench.
Hawkshaw’s impact against his former team was immediate as he started and finished the attack which produced the opening try of the game on eight minutes.
After Darragh Murray pulled off a lineout steal near half way, the ball reached Hawkshaw in midfield where he demonstrated good footwork to make valuable ground.
Then, following rapid recycling, play moved right where Hansen showed quick hands to release centre Byron Ralston who handed off Charlie Ngatai to burst up the touchline.
Ralston found support inside from Test winger Hansen who delivered the one-handed scoring offload to Hawkshaw. It was a fine team try.
Having shown their threat in attack, Connacht then had to demonstrate their defensive resolve as Leinster applied an extended period of pressure.
The challenge became sterner when the hosts were reduced to 14 men on 17 minutes following a yellow card for centre Cathal Forde for head-on-head contact in a tackle on opposite number Ngatai.
But not only did they manage to keep Leinster out, they actually won the ten minute sin bin period 3-0 as Hanrahan stretched their lead following a scrum penalty which delighted the home front row.
But with the game back to 15-a-side, the visitors finally turned pressure into points off a close-range tap penalty, with scrum-half Ben Murphy feeding Ngatai who broke through to the line.
Fly-half Harry Byrne added the conversion to cut the deficit to 8-7 at the break and it was all to play for.
Ten minutes into the second half, Connacht were again reduced to 14 men when loosehead prop Peter Dooley was yellow carded for not retreating ten metres at a tap penalty.
This time, Leinster immediately capitalised on their numerical advantage as South African lock Jason Jenkins forced his way over for a converted try.
The visitors soon extended their lead when hooker Ronan Kelleher pounced on a loose ball in the right corner after Ngatai and Rob Russell both kicked ahead.
Restored to their full compliment, Connacht roared back into the game with a well worked score with 15 minutes to go.
An offload from replacement back row Paul Boyle sent Forde racing over halfway, with the centre keeping his feet despite an attempted ankle tap and putting scrum-half Blade in.
Then, five minutes later, it was over to Hansen.
Receiving the ball midway inside his own half following a turn over, he burst between two defenders and drew the last man before sending Kilgallen racing away for his fifth try of the season, with Hanrahan converting.
As the clock ticked away, it looked as though Connacht were going to see out time for the win, but there was to be one cruel twist to the tale.
Connacht: Tries - Hawkshaw, Blade, Kilgallen; cons - Hanrahan (2); pen - Hanrahan.
Leinster: Tries - Ngatai, Jenkins, Kelleher, Fawley; cons - Byrne (2)