India rout sorry Sri Lanka by 302 runs to seal World Cup semi-final spot
Sri Lanka's woeful innings in Mumbai featured five noughts, with both their openers falling for golden ducks.
Shami took 5-18 in five overs after Jasprit Bumrah and Mohammed Siraj struck with the new ball in an innings with a top score of just 14.
Bumrah, with 1-8 in five overs, and Siraj (3-16 in seven) did the early damage as Sri Lanka slumped to 3-4, chasing 358.
The only bigger winning margin in a World Cup match was the 309-run defeat Australia inflicted upon the Netherlands, a non-Test side, in Delhi just over a week ago.
But this was India's biggest World Cup win, surpassing their 257-run hammering of Bermuda, another non-Test team, during the 2007 edition in the Caribbean.
'Clinical'
"We're very happy knowing we have officially qualified (for the semi-finals) now," said India captain Rohit Sharma after his team made it seven wins out of seven.
"It's been a good effort from the entire squad... It has been clinical," he added.
Sri Lanka's total did top the 50 all out they made in a 10-wicket Asia Cup final defeat by India in Colombo in September.
They also avoided setting a new record for the lowest total in any one-day international, which stands at 35, and going under the corresponding World Cup mark of 36, posted by Canada against Sri Lanka in Paarl, South Africa, in 2003.
These were meagre consolations to a Sri Lanka side suffering their fifth defeat of the tournament, with skipper Kusal Mendis saying: "I'm very disappointed. They bowled really well and got a bit of seam and swing... Mohammed Shami, Siraj and Bumrah, they're great bowlers."
Earlier, Virat Kohli missed out on equalling Sachin Tendulkar's all-time record of 49 one-day international hundreds.
But he still made 88 in an India total of 357-8 and shared a stand of 189 with opener Shubman Gill (92), after the second-ball exit of Rohit.
The duo were out in quick succession but Shreyas Iyer kept the runs coming with a blistering 82 featuring six sixes.
"Shreyas is a very strong man, strong in his mind," said Rohit.
"He did exactly what he is known for, take on the bowlers, take on the opposition and hit sixes."
Facing a daunting chase, the visitors would have wanted a solid start at the Wankhede Stadium - where India beat Sri Lanka in the 2011 World Cup final.
Instead, Pathum Nissanka was lbw for nought to Bumrah's very first ball and at the start of the second over Siraj had Dimuth Karunaratne, the other opening batsman, lbw for nought as well.
Sadeera Samarawickrama survived four balls before he too was out for a duck, edging Siraj to third slip.
Mendis was bowled for one by Siraj to the delight of a raucous crowd.
Shami ensured there was no respite by dismissing Charith Asalanka with just his third delivery.
Then 14-5 was transformed into 14-6 next ball when Dushan Hemantha edged the remorselessly accurate Shami to wicketkeeper KL Rahul.
Dushmantha Chameera survived the hat-trick but was quickly caught behind for nought off Shami, who then clean bowled veteran Angelo Mathews for 12
Sri Lanka were now 29-8.
Mahesh Theekshana and Kasun Rajitha briefly kept India at bay before Shami had Rajitha caught in the slips for 14.
Jadeja ended the match by dismissing Dilshan Madushanka, who had led Sri Lanka's attack with 5-80.
After Rohit was bowled by Madushanka, having lost the toss, Sri Lanka missed two chances.
Gill was on eight when a diving Charith Aslanka dropped a difficult catch at backward point off Madushanka.
Next over, Kohli was reprieved on 10 when Dushmantha Chameera was unable to cling on to a return catch.
The second-wicket duo punished Sri Lanka for those errors before Gill was caught behind off Madushanka, who also had Kohli taken at cover-point off a slower ball.