Patrick Hoban capped what may be his last game for the club with a brace, the second his 150th goal for them, as Dundalk blew relegated UCD away in the second half at the Bowl.
But despite a fifth win from their final six games, it wasn't enough to snatch the potential of a European place as Stephen O’Donnell’s side had to settle for a fifth place finish.
Though enjoying plenty of the ball from the off, Dundalk found themselves behind from UCD’s first attack after just six minutes.
Ciaran Behan wasn’t tracked as he burst forward through midfield to feed Jesse Dempsey in plenty of space on the left.
Hayden Muller failed to cut out the low cross under pressure from Mikey Raggett. The ball ran across goal to the inrushing Michael Gallagher who, despite scuffing his shot, found the net for his first goal of the season.
The woodwork prevented an equaliser on 28 minutes as Dundalk finally put some purpose to their possession, Muller’s drive crashing back off Lorcan Healy’s crossbar.

Archie Davies then worked Healy before Dundalk deservedly levelled five minutes later.
Gallagher’s clearance from Connor Malley’s low cross ran straight to Paul Doyle with the former Student beating Healy with a crisp left-foot shot.
Dundalk again laboured initially to make their possession pay in the second before they broke UCD’s resolve with a three-goal salvo inside seven minutes.
Daryl Horgan skipped in behind onto skipper Hoban’s clever flick to blast to the roof of the net on 64 minutes.
A sublime through ball by Malley threaded substitute Dan Kelly in behind to round Healy and slide home before Hoban added the fourth goal with a trademark header from Kelly’s cross.
The club’s record goalscorer, whose future remains undecided despite having a year to run on this contract, completed the scoring on 86 minutes, scooping home after John Martin’s shot came back off a post.
UCD: Lorcan Healy; Eanna Clancy, Jack Keaney, Evan Osam; Adam Verdon (Brendan Barr 65), Adam Wells; Michael Gallagher (Luke O’Regan h-t), Sean Brennan (Donal Higgins 78), Ciaran Behan, Jesse Dempsey (Danny Norris h-t); Mikey Raggett (Danu Kinsella-Bishop 65).
Dundalk: Nathan Shepperd; Archie Davies, Greg Sloggett, Andy Boyle, Hayden Muller (Sam Durrant 76); Ryan O’Kane (Dan Kelly 54), Connor Malley, Paul Doyle (Robbie Benson 65), Daryl Horgan (Keith Ward 76); Patrick Hoban, Cameron Elliott (John Martin 76).
Referee: Kevin O’Sullivan (Cork).