Ireland's Sam Bennett took victory on stage five of the Tour of Britain, with Team Sky's Sir Bradley Wiggins retaining the overall race lead.
The hilly 177km race from Machynlleth took the riders over the Brecon Beacons and ended with two ascents of Caerphilly Mountain, which reduced the leading group to around 20 riders.
Bennett, second on stage two, sprinted clear in the final 100m to win.
Wiggins was seventh to stay 37 seconds ahead of team-mate Ian Stannard.
Bennett told ITV4: "I'm delighted with this week. It was a hard finish and I can't believe I got it.
"I knew if I hung on up the climb I would recuperate quick enough for the sprint."
The 22-year-old riding for An Post-Chain Reaction, outsprinted Michal Golas and Martin Elmiger to record his first stage victory.
Stannard paced gold-jersey holder Wiggins over Caerphilly Mountain and kept the group together to preserve the 2012 Tour de France winner's lead with three stages remaining.
"I rode this last week so I knew it would be the Queen stage," said Wiggins.
"I'm nothing without the team and they rode all day, controlling the race. I used Ian and David Lopez right until the last kilometre and they left me just having to sit there."
Wiggins has previously had a disappointing 2013, having to pull of the Giro d'Italia through illness and missing the Tour de France through illness and injuy.
However, he remains on course to become only the second home winner of the Tour of Britain since its reincarnation in 2004, and the second in as many years after Jonathan Tiernan-Locke's triumph.
"I've worked hard for 20 weeks to be in this condition," he said. "It's been a long road but this is where I wanted to be at the start of the week."
Referring to his style of climbing, the four-time Olympic gold medallist said: "I don't have the acceleration that some I have. I just time trial. I pace my efforts and it works. I won the Tour de France like that."
Friday's sixth stage begins in Sidmouth, with the riders taking in the 138km route to Hayter on Dartmoor for the first summit finish in the Tour's history.
1. Sam Bennett (Ire) AN Post Chain Reaction 4hrs, 35mins, 29secs
2. Michal Golas (Pol) Omega Pharma Quick-Step at same time
3. Martin Elmiger (Swi) IAM Cycling at same time
4. David Le Lay (Fra) Sojasun at same time
5. Jack Bauer (NZ) Garmin Sharp at same time
1. Sir Bradley Wiggins (GB) Sky Procycling 16hrs, 11mins, 36secs
2. Ian Stannard (GB) Sky Procycling at 37 secs
3. Martin Elmiger (Swi) IAM Cycling at 43 secs
4. Jack Bauer (NZ) Garmin-Sharp at 55 secs
5. Michal Golas (Pol) Omega Pharma Quick-Step at 1min, 12secs