The Queen was narrowly denied a Royal Ascot winner once again as Contributer (9/1) swept down the outside to defeat her runner Bold Sniper in the Listed Wolferton Handicap.
A day after Royal runner Estimate finished a close second in the Gold Cup, Bold Sniper was sent off the 2/1 market leader for this mile and a quarter event.
And, after the likes of Dick Doughtywylie and Sennockian Star had cut out the pace, a roar went up from the crowd as Ryan Moore eased the Sir Michael Stoute-trained favourite into a challenging position at the furlong-pole.
But Contributer, who had raced in last place early on, having been drawn on the outside in stall 15, showed a good turn of foot to storm down the outside and take it up just inside the final furlong, before running on strongly to score by half a length and give rider George Baker his first ever Royal Ascot winner.
Cafe Society (6/1) stayed on nicely despite not getting a brilliant run, to finish a length and three-quarters further back, and he will now go to race in Australia for his new trainer Gai Waterhouse.
It was a second success in three starts this season for the Ed Dunlop-trained winner, who was fourth in a Group 2 at this meeting last year.
A delighted Baker said: “I've had so many seconds here, I thought it was never going to happen, but it's fantastic to win one.
"This horse ran on very heavy ground at Sandown behind Noble Mission (when third last time). If he hadn't run there, he'd have been a lot shorter in the betting.
"It was a good performance. I was drawn very badly and Mr Dunlop told me to ride the race as it happened. I took my time and it all went to plan."
American George Bolton owned the winner and said: “This is the highlight of my racing career. To come over to Royal Ascot and win a race is very exciting.
"I'm so proud of him (Baker). I thought he was too far back, but he's given him the perfect ride."
It has been a difficult first half of the season for Dunlop, many of whose horses have been suffering with a bug.
"This is a big deal,” he said. “It's been a tough year. This is George's first horse in England and he's won at Royal Ascot, so I'm delighted for him.
"We've always thought a lot of the horse. He was second to Magician in the Dee Stakes and ran very well against Noble Mission at Sandown.
"He carried a lot of weight today, he's a Group horse. He was always my best two-year-old.
"He's in the Meld Stakes in Ireland (20 July at the Curragh) and will have other Group options."
Waterhouse was pleased with Cafe Society and said: “I think he's a really exciting horse and that was a very solid run.
"We'll keep him ticking over until the first lot of horses leave England for quarantine, and then I'll bring him down and assess him and start to make a plan.
"Hopefully he might be a Melbourne Cup horse in a year's time."