Dundalk's hopes of winning the eircom League of Ireland First Division title were left hanging by a thread after a Cathal Brady-inspired Kildare County produced a major upset.
Kildare were the better side throughout the game and really, if anything, they deserved to win by more.
Brady had already been denied by an excellent save by Chris Bennion before he opened the scoring after 14 minutes. Barry Clancy split the Dundalk defence with an excellent through ball and Brady lifted the ball superbly over the onrushing Bennion.
Despite playing five across the midfield, Kildare continued to push forward and Stephen Cooling and Brady got forward at every opportunity to support lone striker, Philip Gorman.
Gorman should have doubled Kildare’s lead after 35 minutes when Cooling’s free-kick found him unmarked on the edge of the six yard but his header when agonisingly wide.
John Gill showed his disgust at his team's first half performance by making two changes at the break. However this had little effect, and indeed the game was soon over as a contest with Kildare scoring twice in the opening eight minutes of the half.
Eoghan Carew scored his second goal in two games after 50 minutes when he reacted quickest inside the box after Gorman's header had been blocked by Flanagan and the County midfielder smashed the ball past Bennion from eight yards out.
Three minutes later, Brady got his second of the game when he broke the Dundalk offside trap to collect Cooling's ball and he raced forward 40 yards before slotting the ball past Bennion.
A strangely lacklustre Dundalk had little answer to Kildare on the day, although they did pull a goal back in the dying moments when Austin O'Neill hauled Philly Hughes down inside the area.
O’Neill actually injured himself in the challenge and had to be replaced but as Kildare had no substitute 'keeper on the bench, striker Philip Gorman pulled on the gloves for the final moments.
His first duty was to pick Trevor Vaughan's well-struck penalty out of the net but that was too little too late for Dundalk who have it all to do now to get themselves back in the running for the title.
Kildare County: O'Neill (Barret, 87 mins); Donnelly, Stapleton, P Byrne, Malone (McArdle, 69); Brady, A Byrne, Carew, Cooling, Clancy; Gorman.
Dundalk: Bennion; Quigley, Crawley (Hand, 64 mins), Flanagan, McGauley, O'Connor, Marney (Smith, h/t), R Dunne, McArdle (K Dunne, h/t); Hughes, Vaughan.
Referee: P Whelan (Dublin).