Liam Craig's dramatic last-gasp leveller against Dundee United at McDiarmid Park secured St Johnstone a top-six place in the Scottish Premier League.
United's 17-year-old forward Ryan Gauld, starting for the first time, took only 23 minutes to make an impact when he raced on to a Mark Millar pass to knock the ball past Saints keeper Alan Mannus.
With 12 minutes remaining United midfielder Stuart Armstrong was sent off by referee Iain Brines when he picked up a yellow card for simulation inside the Saints box, after being booked early in the game for a challenge on Gregory Tade but in the third minute of added time, Craig leapt to head in a corner from substitute Mehdi Abeid, who had replaced Tom Scobbie.
It was probably a deserved point for the Perth side who remain four points ahead of sixth-placed Kilmarnock while United, with one game against Aberdeen remaining before the split, have to wait and see if they can make the top half of the table.
Saints boss Steve Lomas made three changes as he looked for the Perth side's first league win over United since 2000.
Frazer Wright, Scobbie and Tade came in for Callum Davidson, David McCracken and Nigel Hasselbaink, with only the latter starting as substitute.
Gauld, 17, was handed his first start as Gary Mackay-Steven could not recover from a hamstring injury sustained on international duty with Scotland.
Also into the visitors' line-up came midfielders Willo Flood and Michael Gardyne with Richie Ryan and Rory Boulding on the bench.
There was a decent travelling support inside the ground as United looked the more likely in the early stages.
In the fourth minute Barry Douglas crossed to the far post for Keith Watson but his fellow defender had to stretch to meet the ball and could only head past.
However, it was an indication of United's early desire although the game quickly descended into a bit of a midfield scrap with possession changing hands, at times, by the second.
In the eighth minute United midfielder Armstrong was booked by referee Brines for a crunching tackle on Tade, which was to prove significant later.
United's goal midway through the first half came courtesy of the type of slack play which characterised the first period.
Craig got caught in possession by Millar who fed it into the path of Gauld and the youngster raced through the middle and beat Saints defender Steven Anderson to toe poke the ball past Mannus.
It was a goal the Tannadice men deserved on the balance of play but Saints at least stepped up their efforts.
In the 36th minute Rowan Vine's near post corner found striker Steven MacLean and his flick almost caught out United keeper Radoslaw Cierzniak who had to concede a corner which the visitors defended.
St Johnstone huffed and puffed all the way to the interval to no avail and they looked no more direct or incisive at the start of the second period.
Tade had an opportunity when he got the break of the ball in a challenge with United defender Brian McLean but his volley from 25 yards limped past the post to the groans of the home support.
On the hour mark Craig's long-range shot was saved for a corner by Cierzniak, which sparked a further moment or two of panic in the United penalty area.
From Craig's corner, Douglas cleared Murray Davidson's header off the line and when the ball came back into the box, MacLean had a looping header tipped on to the post by Cierzniak before Watson completed the clearance.
Tade was replaced by Hasselbaink as United began defending increasingly deeper and in the 75th minute Davidson headed a Vine corner over from close range.
Three minutes later Armstrong was shown a second yellow card for simulation inside a crowded penalty area in his attempt to win a penalty.
As Saints pressed for the equaliser, Davidson had a low drive well saved by Cierzniak and in the final minute of normal time MacLean was presented with a great chance when the United defence got itself into a mess but he hammered the ball over the bar from 10 yards.
However, drama was reserved for the third of four added minutes when Craig rose to head in Abeid's corner to send the home fans wild.