Making the most of a series of extraordinary incidents and interventions in an action-packed race, which included three safety auto interventions and a red-flagged stoppage, Ricciardo, who started 10th, roared home 3.904 seconds ahead of the rest to deliver his first win of the season.
At the race re-start of the second safety auto period at lap 17 Lewis Hamilton who was leading from pole and the beginning of the race was seen brake-testing Sebastian Vettel who was behind him in second place by then. Then it takes a bit of a while and in the end you don't have time to develop a rhythm you just have to go for it.
"I think it's one of the tracks where you need to have the vehicle in the window and tyres in the window, and then, if you feel confident, you extract a lot of lap time as well".
Stroll's performance makes him the first Canadian to finish on the podium since Jacques Villeneuve came third - the last of his 23 podium finishes - in the German Grand Prix in 2001.
Red Bull's Daniel Ricciardo won in Baku after a chaotic race which saw Ferrari's Vettel given a 10-second stop-go penalty when he steered into the back of race leader Hamilton's Mercedes under safety vehicle conditions after a red-flag stoppage on lap 22.
With the safety vehicle out for a third time, as debris littered the 3.7-mile track following a number of collisions through the pack, Vettel rammed into the back of Hamilton.
Racing resumed, for a third time, on lap 19, but only after the incident in which Vettel hit the rear of Hamilton's vehicle, under braking as the leader tried to avoid the slow-moving safety auto.
Vettel, 12 points ahead of Hamilton in the championship race, threw both hands up in the air before pulling alongside his rival and then appearing to deliberately drive into the Briton.
Vettel got a 10 second penalty for the infraction, but Hamilton lost ground by having to pit.
Within moments, the safety auto was out again for the third time after Sergio Perez and his Force India teammate Esteban Ocon collided.
The pair had previously spoken in high regard of each other in the title race, in contrast to the frequent verbal digs Hamilton gave former teammate Nico Rosberg during their duels in previous seasons.
Chile draws with Australia to reach Confed Cup semifinals
As Group B winners, the Germans will face Mexico in the semi-finals in Sochi. Then came the red-card confusion, swiftly followed by Germany's second goal.
Niki Lauda, the non-executive chairman at Hamilton's Mercedes team, was equally scathing of Vettel, saying: "He freaked out in himself". We were side by side at as we crossed the line, but what a race!
Shortly before that, the Hamilton-Vettel incident occurred. I don't even know what to say. No question. But to drive next to him and hit him on goal, I have never seen anything like this.
Vettel was in no mood to take the blame, however.
Things settled down for a short while after that, but then came a hat-trick of safety auto periods, each of which only led to more drama.
Perez was seemingly forced out of the race as too was Raikkonen, whose right rear tire was completely shredded.
Both days, drivers were severely tested on the track, which is volatile and unpredictable due to a combination of long straights, blistering track temperatures, and hard-braking corners.
With debris littering the track, it was deemed too unsafe to race and the red flag came out on lap 22 of 51.
It appeared Hamilton had done nothing untoward, but the German was clearly irate and pulled alongside the Mercedes, waving an arm, before turning into his auto. Vettel was consequently struck with a ten second penalty. With Ricciardo out, the six-way fight for pole was down to just five.
But Vettel defended himself and insisted Hamilton should also have been punished.
The race also saw Fernando Alonso finish ninth to claim McLaren's first points of the season.
- Congress hears sinister tale of Russia election meddling
- Hundreds of civilians killed, injured in Mosul's Old City
- Off-duty black St. Louis cop mistakenly shot by white cop
- Heller won't back Senate GOP health care bill
- Jurors Acquit Ex Cop Who Fatally Shot Sylville Smith
- New Zealand wins 5th straight vs Oracle in America's Cup
- UAE warns Qatar to accept demands or face 'divorce'
- Rebels say Syrian army, Iranian-backed militias launch offensive in eastern desert
- Ronaldo ready to pay $16.39 million in Spanish tax fraud case
- Prince Harry admits doubts about his royal service