Dundalk moved eight points clear at the top of the Eircom League First Division with victory over Shelbourne in front of a packed Oriel Park.
The Lilywhites made the vital breakthrough after 14 minutes. Dessie Baker's clever free-kick found David Cassidy just outside the six-yard box. He lost his footing at the vital moment but Robbie Farrell was on hand to sweep home the loose ball after some hesitation in the Shels defence.
Baker went close to doubling the lead just two minutes later with a beautiful volley from 20-yards but it was the visitors who controlled the rest of the half without ever really threatening the Dundalk goal.
Anto Flood had a half-chance following a mistake by Chris Bennion but Paul Marney was on hand to hack the centre-forward's header while David McGill went close with a 25-yard effort.
Alan Keely had the visitors' best chance of the half but he misguided a header wide from McGill's corner.
The Shels centre-half then made a fatal mistake to gift Dundalk their second just three minutes into the second half. His slip gifted Baker possession on the right and he picked out David O'Connor who made no mistake from 12 yards.
The Reds threw men forward in a desperate bid to retrieve something from the game and Bennion had to tip a McGill free-kick round the post. Keely set up a tense finish with his 83rd minute header which crept over the line but Dundalk held on for what could be a season defining victory.
Dundalk: Bennion, Marney, Grimes, Kelly (Ryan, 69), Whelehan, Shiels, Duffy (Crowley, 60), Cassidy, Farrell (Mulvenna, 71), Baker, O'Connor
Subs: Crowley, Mulvenna, Doyle, Ryan, Shanahan.
Shelbourne: Delaney, Murphy (Forsythe, 59) Hedderman, Keely, Brennan, O'Brien, McGill, Chambers, Flood, Gorman, Keddy (Rutherford, 59).
Subs: Freeman, Forsythe, Byrne, Rutherford, Whelan.
Referee: Paul Tiute