Safely tucked away for most of the 148km from Unley to Stirling and delivered expertly in the finale by his team-mates, Ewan jumped on the world champion's wheel in the final graft to the finish, rocketing past Sagan's left and over the line.
Daryl Impey finished ahead of Sagan's team mate Jay McCarthy to deliver a one-two punch for Mitchelton-Scott.
Victory in an uphill drag is further proof Ewan can win the more punchy races, cemented too by his fourth place in the recent undulating national championships road race behind team-mate Alex Edmondson.
The 23-year-old was relieved to deliver a win for his team after his lack of success in the People's Choice Classic on Sunday and yesterday's stage.
"It’s just good to get that confidence back up after the last two races," he said. "It was a super tough finish. It was one where we were unsure about if I’d make it over the top but the boys put me in the perfect position again.
"I just love seeing them back me 100 per cent even after some results we weren’t hoping for and for them to back me on a stage that probably doesn’t even suit me means a lot."
"I hid pretty well in the field. I’ve done this circuit before so I know where I can relax and when I need to be at the front the boys knew the same thing: relaxed where we could and went hard where we needed to.
"I heard on the radio that [Andre] Greipel had been dropped on the last climb so I’m so happy to be back in ochre."
It was almost déjà vu with Scott Bowden (UniSA), William Clarke (EF Education First) and Nicholas Dlamini (Dimension Data) away again from the flag after their breakaway efforts on yesterday's stage. This time joined by Movistar's Jaime Castrillo. The trio quickly established a lead of over three minutes by the time they reached the KOM after 12.6km raced.
Bowden bowed out before the final kick on the climb and called for the team car, while Dlamini, resplendent in the KOM jersey took on Clarke for the 10 points, the Australian breakaway specialist just beaten on the line as Castrillo looked on, distanced by the pair's acceleration.
With the KOM jersey retained, Dlamini journeyed back to the peloton while Clarke, Castrillo and a regrouped Bowden extended their lead to just over four minutes after 15km raced. This blew out to six minutes and 30 seconds after 34km and the temperature too soared towards 37 degrees.
Concerned the advantage was looking unmanageable, Bahrain-Merida massed its troops at the front with around 90km to go and led by Ramunas Navardauskas, soon pegged back the gap to four minutes and 25 seconds just five kilometres later.
By the time the three leaders contested the sprint - easily won by Clarke over Bowden - at 71km to go, the gap was down to just over three minutes. But Clarke who'd done enough to nab the maximum sprint points immediately sat up and with Bowden beside him, pedalled casually, waiting for the bunch.
Castrillo held a three minute lead over the bunch the first time through Stirling with around 64km left to race and valiantly held on to a minute's lead the final time through the start/finish with 21km to go.
Control over the pack was never really wrested from Bahrain Merida's grip until around 14km to go when the bunch finally caught Castrillo, and EF Education First, Lotto Soudal and Sunweb all jostled for the best position at the front.
But the seven kilometre dig toward the finish reduced the peloton somewhat until just the puncheurs remained on the ramp to the finish.