Pakistan thumped Bangladesh by 94 runs in their final World Cup group match on Friday but it was not enough to earn them a place in the semi-finals as New Zealand went through on net run-rate.
Sarfaraz Ahmed's team needed to smash the world record for margin of victory in a one-day international after winning the toss to keep the dream alive, but a miracle win never looked remotely likely at a sun-drenched Lord's.
Their total of 315 for nine meant Bangladesh needed only eight runs to end Pakistan's hopes of progress at the tournament and they reached that in the second over.
Teenager Shaheen Afridi took six wickets as Pakistan won the game easily to finish level on 11 points and games won (five) with fourth-placed New Zealand, leaving them outside the top four due to their inferior run-rate.
The other teams in next week's semi-finals are Australia, India and hosts England, with the final group matches taking place on Saturday.
Shaheen Afridi appreciation post 🤩
👉 16 wickets at #CWC19
👉 Youngest to take a five-for at a World Cup
👉 Most wickets by a teenager in World Cups
👉 Best figures by a Pakistan bowler at a World Cup pic.twitter.com/8OUJIdsjtY
Pakistan, backed by thousands of passionate flag-waving fans, started curiously slowly, crawling to 38-1 after 10 overs.
Imam-ul-Haq (100) and Babar Azam (96) eventually stepped on the gas, reaching their 150 partnership for the second wicket off 146 balls but both fell in quick succession to suck the momentum out of their innings.
A late flourish from Imad Wasim, who scored 43 runs from 26 balls, boosted the score but Pakistan lacked the muscle to put themselves out of sight.
Mustafizur Rahman took five wickets for Bangladesh, including a superb caught and bowled to dismiss Shadab Khan.
In reply, Shakib Al Hasan (64) scored his seventh fifty of the World Cup to shoot to the top of the tournament's run-scoring charts, with 606 runs at an average of more than 86.