Pole winner Anton De Pasquale made the best of the start in cold, drizzly conditions, the Shell Ford driver initially leading Kostecki and van Gisbergen.
Kostecki made life hard for himself soon after, though, showing the nose on De Pasquale at Turn 3 which then compromised his exit.
That allowed van Gisbergen to charge into second place at Turn 5 before he set after the leading Mustang.
It didn't take long for van Gisbergen to charge into the lead, the Kiwi breezing past De Pasquale into Turn 3 on the third lap.
Kostecki, meanwhile, then came under pressure from Cam Waters, who ended up on the outside of the Erebus Camaro on the exit of Turn 10 while trying to get by on Lap 5.
The excursion slightly wide sent the Monster car backwards through the field, Waters dropping to sixth as he scrambled back onto the road.
There was more action in the lead group on Lap 12 when Will Brown charged inside Chaz Mostert into Turn 1 to grab fourth place.
Out front van Gisbergen was able to ease away from De Pasquale across the first stint, while Kostecki steadily worked his way back under De Pasquale's rear wing.
On Lap 15 Kostecki made his move, diving under De Pasquale at Turn 11 to take over second place.
Interestingly the first stint stretched almost the entirety of the race for most of the field, the top 15 all waiting until the last three laps to take their mandatory service thanks to the durability of the super soft.
De Pasquale, and Brown went on the third-last lap, a slow stop for De Pasquale dropping him from third on the road right back to sixth in the order.
Van Gisbergen, Kostecki and co then pitted at the end of the second-last lap, Triple Eight and Erebus taking advantage of the wet race declaration to opt for two new super softs rather than four new hard compound tyres as otherwise required by the rules.
A slightly slow stop for van Gisbergen did allow Kostecki to close up on van Gisbergen leaving the lane, but the reigning champion was able to hold on to take victory by three-tenths.
"Thanks to Dunlop; normally they don't get much praise, but I think it's good that they've done a good job here," said van Gisbergen. "No tyre failures, so thank you to them.
"Again thanks to my team. What I did to the car this morning – tried to write the thing off – and to fix it it up like they did, two good qualis and then a race win, I'm stoked."
De Pasquale's issues during the stops promoted Brown to third place, while Feeney used his two-tyre stop to leapfrog his way up to fourth.
That dropped Mostert to fifth ahead of De Pasquale and Waters.
Jack Le Brocq came home eighth for Matt Stone Racing, from James Courtney and Macauley Jones, who was another driver to run the two-tyre strategy to make up spots.
Mostert continues to lead the series with a 31-point margin over Kostecki. Van Gisbergen, meanwhile, is now 106 points behind Mostert in seventh.
The Melbourne SuperSprint continues tomorrow with a second sprint race starting at 2:55pm local time.