Bohemians...3 Shamrock Rovers...2
Colin Hawkins scored a late winner as Bohemians came from behind twice to maintain their seven-point lead at the top of the Premier Division table with just six games to go.
Hawkins's 78th-minute goal was a bitter pill to swallow for Rovers and for former Gypsy Trevor Molloy in particular, who scored twice and then missed the chance of a hat-trick before Bohemians turned a thrilling game on its head.
Bohemians had the luxury of naming an unchanged side following their comfortable win at Bray Wanderers last week. Rovers, though, were forced into a straight switch up front, with Tony Grant coming back from injury to replace their suspended leading scorer, Noel Hunt.
It was Grant's strike partner Molloy's first return to Dalymount since his move from Bohemians to Carlisle United in the summer, and he took little time to make himself at home by opening the scoring after just nine minutes.
Paul Caffrey deserves much of the credit for Rovers' lead. Indeed, the midfielder had given warning of the influence he was to have early on when he ended a move involving Tony Grant and Molloy by shooting into the side netting.
Minutes later he took possession of a Shane Robinson corner after Bohemians failed to properly clear. Catching a defender wrong-footed, Caffrey raced to the end line to cross low to the near post for Molloy, who had won the corner off Colin Hawkins, to score via Ashley Bayes's crossbar.
Molloy was there again to torment his former club eight minutes later when he forced an awkward save from Bayes after Stephen Grant and James Keddy had worked the opening.
Bohemians, who gradually came back into the game, equalised from a set-piece on 21 minutes. Rovers didn't defend Ryan's free-kick from the left and central defender Derek Coughlan used his height to glance a header past O'Dowd.
Ryan then shot into the arms of O'Dowd minutes later after Paul Keegan knocked down Simon Webb's long free-kick as Bohemians looked to have taken command.
But it proved a false dawn for Stephen Kenny's side as Rovers, who always looked dangerous when they got forward, punished further poor defending to regain the lead three minutes before the interval.
Following a Stephen Gough free-kick, Stephen Grant's shot hit the post before Caffrey fired the ball back across the face of the goal, with Molloy eventually taking possession in a crowded area to virtually dribble the ball over the line.
Bohemians levelled the match again within seven minutes of the second half thanks to sloppy defending from Rovers.
Hunt's hard running was rewarded as he retrieved Keegan's ball at the end line, hooking it over the head of the out-of-position O'Dowd for Crowe to score an easy goal.
Three minutes later, Molloy should have put the gloss on his Dalymount return with a hat-trick to restore Rovers' lead, but he missed an absolute sitter. Set up by Tony Grant, Molloy turned well only to somehow blaze his shot high over the bar.
It was to prove a costly miss as Bohemians secured their win with another set-piece goal on 78 minutes.
This time it was Hawkins who rose well at the back post to head home substitute Fergal Harkin's corner.
BOHEMIANS: Bayes; O'Connor, Coughlan, Hawkins, Webb; Ryan (Lynch 88 mins), Hunt, Caffrey, Rutherford (Harkin 65 mins); Crowe, Keegan (O'Neill 71 mins).
SHAMROCK ROVERS: O'Dowd; Gough, Palmer, Byrne, Keddy; Robinson, Dimech, Caffrey, S Grant; A Grant, Molloy.
Referee: J O'Neill (Waterford)