The Dons headed into the match on the back of a dreadful 11-match winless streak but goals from Zander Diamond and Sone Aluko gave them a two-goal lead.
Steven Robb pulled a goal for the Buddies with 11 minutes remaining and Aberdeen's Steve MacLean saw red for a second bookable offence three minutes later to set up a nervy finish, but the Reds hung on for a welcome triumph.
Aberdeen made two changes with Italian defender Davide Grassi replacing the injured Jim Paterson and MacLean preferred to Darren Mackie in attack.
St Mirren arrived at the Granite City in buoyant mood after their emphatic 4-0 midweek win over Celtic.
Gus MacPherson made one change from his starting XI with Michael Higdon replacing striker Billy Mehmet, who dropped to the bench.
The hosts made a lively start with Sone Aluko darting down the right before crossing for Stuart Duff but the former Dundee United player's shot was easily blocked by ex-Don Lee Mair.
Aberdeen's MacLean was cautioned after seven minutes for an off-the-ball incident spotted by the assistant referee before the striker carved out an opening for Derek Young after 12 minutes, but the midfielder fired wide from the edge of the area.
The visitors almost broke the deadlock a minute later when Higdon's header from Steven Thomson's cross was cleared off the line by Charlielgrew.
Richard Foster had a chance to test Paul Gallacher following a superb run past three players but his left-footed effort hit MacLean and trickled harmlessly into the path of the St Mirren goalkeeper.
Mark McGhee was forced to make an early change after 27 minutes with the injured Young replaced by Fraser Fyvie, who was celebrating his 17th birthday.
Craig Dargo volleyed over the bar after Diamond had failed to deal with Jack Ross' searching ball into the area as the Buddies enjoyed a rare period of sustained pressure.
But it was Aberdeen who opened the scoring after 37 minutes. Gallacher pulled off a smart save to keep out Diamond's bullet header but the Dons defender reacted quickest to smash the rebound high into the roof of the net.
The home support were appealing for a penalty within two minutes of the restart when Michael Paton fell under pressure from John Potter in the area but referee Brian Winter waved play on.
The Dons pressed for a second against a jaded-looking St Mirren with Aluko flashing two efforts just wide of the target.
Aberdeen's second eventually came in bizarre circumstances after 56 minutes. Fyvie centred the ball for Aluko whose low shot took a wicked deflection off Ross before trickling into the goal despite the best efforts of Gallacher and Potter.
St Mirren introduced Mehmet and Graham Carey for Garry Brady and Andy Dorman as they looked for a route back into the game.
Gallacher denied Fyvie a birthday goal when he made a smart save to push the young midfielder's header from MacLean's cross around the post after 78 minutes.
The Buddies grabbed a lifeline when Mehmet's cross fell kindly into the path of Robb who clinically drove the ball past the helpless Jamie Langfield with 11 minutes to go.
Things got worse for the Dons when MacLean was shwn a second yellow card for a late tackle on substitute Carey after 83 minutes.
Mehmet fired inches wide in the closing stages and Langfield pulled off two sensational stops to deny substitute Rory Loy, who had replaced Thomson, and Higdon but the equaliser was not forthcoming for the visitors.