The home side went into the break with a one-goal advantage, Adam Rooney scoring from the spot after Garry Wood had been hacked down by Franco Miranda.
But the Buddies got back on level terms after the break when Billy Mehmet poked the ball past Michael Fraser
And a goal 10 minutes from time by Gary Brady was enough to give Gus MacPherson's side all three points.
Inverness club captain Grant Munro had to be content with a substitute role after his return from injury as Craig Brewster started with the same XI who beat Falkirk a fortnight ago.
Jim Hamilton and Mehmet started up front for St Mirren, with former Caley favourites Dennis Wyness and Craig Dargo on the bench.
Inverness were in the ascendancy early on and had the first chance in the second minute when Ross Tokely's free-kick found Rooney in space, but Wood was not quick enough to make anything of his knockdown.
Wood had another chance in the eighth minute when he met a driven cross from Don Cowie but his effort fell easily into the arms of Mark Howard.
A minute later, Ian Black found himself with time and space on the edge of the St Mirren box but his effort flashed high and wide.
St Mirren had their first chance after 15 minutes when Steven Robb's corner fell to Garry Brady on the edge of the box but he dragged his effort harmlessly wide.
Only good defending from Phil McGuire prevented Andy Dorman getting a shot away in the 22nd minute and seconds later the ball fell kindly to Hamilton but his effort went agonisingly wide.
The visitors appealed for a penalty in the 26th minute when Gary Mason fell in the box under pressure from Black but referee Iain Brines waved play on.
Slack play from Hamilton allowed Vigurs to break and his threaded ball put Rooney through on goal but the Irishman's effort was well blocked by Buddies captain John Potter.
Vigurs and Cowie switched flanks and this change seemed to halt the St Mirren pressure temporarily. Cowie raced forward to send in a threatening ball but
Howard collected, with Rooney and Wood ready to pounce.
Vigurs then flashed a shot wide of Howard's left post in the 37th minute as Brewster's tactical tinkering looked to be paying dividends.
Inverness did take a deserved lead in the 43rd minute from a penalty.
Tokely threaded a clever ball through to Wood, who was hacked down in the box by Miranda.
Referee Brines had no hesitation in pointing to the spot and Rooney smashed the ball low and hard into the back of the net.
The home side could have doubled their advantage when Cowie and Black linked up well and the former shot straight at Howard from the edge of the box.
Caley started the second half with a bang, Rooney almost capitalising on a Will Haining mistake but his effort smashed off Howard's bar.
The home side were almost made to pay for that miss when veteran forward Hamilton's header from a Robb cross went just wide when the experienced striker should really have scored.
Howard produced a terrific save at full stretch 10 minutes into the second half to deny the impressive Wood as Inverness looked to put the game beyond doubt.
The away supporters were not happy with referee Brines when he stopped the game as the Buddies were on the attack so that McGuire could receive treatment after clashing with one of his team-mates.
However, there was something to cheer about after 61 minutes when Mehmet out-sprinted Duff and McGuire to poke the ball past Fraser and level.
Caley replied immediately, the tireless Vigurs shooting over from 25 yards.
Howard then pulled off a miraculous save when a Rooney shot was almost deflected into his own net by Haining, the Buddies keeper somehow saving with his feet.
Both sides freshened things up after 72 minutes, with Dougie Imrie replacing Vigurs for the home side and Saints' Stephen McGinn coming on for Robb.
Four minutes later, Caley brought on Andy Barrowman and Barry Wilson for Rooney and McBain as the home side looked to win the game.
But it was the visitors who went into the lead in the 80th minute when substitute McGinn got the better of Tokely on the touchline and his cross fell kindly for Brady, who smashed the ball high into the roof of the net.
Soon after, Tokely was booked for taking out his frustrations on Hamilton.
With six minutes remaining, Barrowman headed wide from a Wilson cross as St Mirren looked set to record their first win of the season.
In the closing stages, Dargo came on for Mehmet to face his former club. Buddies keeper Howard was cautioned late on for time-wasting but his side held out to record their first win of the season.