Dundee made several changes with Aaron Donnelly, Mo Sylla, Scott Tiffoney, Amadou Bakayoko and Zach Robinson came in for Lee Ashcroft, Owen Dodgson and Michael Mellon, who were on the bench, and the injured pair of Malachi Boateng and Curtis Main. Dundee switched to four at the back, instead of the usual three with wing backs.
Most of the first twenty minutes was all around the St Johnstone's box but Dundee failed to create anything which was clear cut. As sometimes it happens St Johnstone scored soon after when Smith scored with a low shot it was a simple goal and totally against the run of play.
Dundee hit back and Cameron had a shot saved then Bakayoko seen his effort rebound off the post, St Johnstone were quite happy to sit back and hit Dundee on the break.
Saints did have a couple of chances before half-time but Carson saved well and Owen Beck showed why he is a top player when he defended well.
At half time Dara Costelloe came on for Zach Robinson. He played in the same wide attacking role on the right and looked more comfortable there than Robinson did, and happier than he had done previously in a deeper wing back role.
After a hour Carson had a great save to deny Saints a second goal, and they hit the bar soon after. Dundee then put Michael Mellon on eith Scott Tiffoney coming off.
Into the last 15 minutes and the game totally changed when McCowan cleared a Saints attack, then it a penalty review with VAR was being done but for who?
Minutes later it was a penalty to Dundee after Bakayoko was fouled in the box. Up stepped Luke McCowan to score with ease to level the game.
Beck smashed a low shot across goal after being played in by McCowan. A Costelloe cross to the far post found Bakayoko but the striker didn’t make a clean enough connection and Mitov smothered the shot.
The Dark Blues kept pressing and got their reward after 89 minutes. Beck drifted infield and a perfect deep cross found Jordan McGhee, who timed his run precisely to nod the winner past Mitov and into the corner of the net from 12 yards.
Eight minutes of injury time was added and the main reason was a bad head knock to Michael Mellon who needed 7 minutes of treatment and care for him to leave the pitch.
Dundee saw out the time to claim three vital points, and it will keep the club in the top six.
Dundee: Carson, McGhee, Shaughnessy (c), Donnelly (Lamie 88) Beck; Cameron,Sylla, McCowan
Robinson (Costelloe at half time), Bakayoko, Tiffoney (Mellon 66 (Ashcroft 104)).Unused Subs: Sharp (gk), Dodgson, Astley, Mulligan, Robertson.
Referee: David Munro
Att: 7,102