The 26-year-old, who dropped to right-back following Chris Innes' first half sending-off, popped up at the back post to head home Graham Carey's cross with five minutes remaining to seal a 1-1 draw on Saturday.
The result leaves Gus MacPherson's side four points clear of basement outfit Falkirk and second bottom Kilmarnock.
Even though there are still six points to play for this season, a vastly superior goal difference over their relegation rivas coupled with the fact Kilmarnock and Falkirk lock horns on the last day of the season means the Paisley side can look towards another campaign in the top flight.
O'Donnell, who was mobbed as the fans crashed through the advertising boards to celebrate his goal, said: "That will probably be the most important one I've scored.
"I said to the manager there are not many right-backs that will go and take a chance at the back post like that at the opposite end of the pitch.
"At that stage, we were down to 10 men, we were told to keep it tight for 20, 25 minutes and then we would go for it.
"I think at that point it's win or bust so you have to go and take a chance. Luckily for me, it's dropped and I've got my head on it."
St Mirren's game plan fell apart minutes before the break when Innes was sent off and conceded a penalty for head-butting Brian McLean.
Scott Arfield dispatched the spot-kick to put the hosts in the driving seat.
Falkirk enjoyed the lions' share of possession after the break but were punished for failing to capitalise on their numerical advantage when O'Donnell levelled the score.
And the former Dundee United and Clyde playmaker insists they showed commendable fighting qualities to battle back.
He added: "I think Chris knows himself that he's had a moment of madness and he left himself down and everyone down at that point.
"The boys have shown huge character, going down to ten men in a game like that and coming away with a point, that's bottle for you.
"It would have been easy for us to go into our shells after going down to ten men and losing the penalty but all credit to the boys, it's a massive result and every one of them were magnificent."