Juan Miguel Mercado won the 18th stage of the Tour de France, leading home compatriot Vincente Garcia-Acosta.
The Spanish pair, part of a six-man breakaway that had been together most of the day, broke for home on the fast run-in with 10km to go.
Mercado edged out Garcia-Acosta by the narrowest of margins in a sprint at the end of the 166.5km stage.
The peloton was more than 11 minutes down, but Lance Armstrong maintained his stranglehold on the race lead.
Mercado made his first break of the day after eight kilometres when he jumped free of the peloton with Garcia-Acosta, Dmitriy Fofonov, Sebastian Joly, Marc Lotz and Juan Antonio Flecha.
As the day's racing began to settle they were surprisingly joined by Armstrong, who marked a break by Filippo Simeoni to ensure it came to nothing.
Simeoni, aware that the peloton would chase down any group including the yellow jersey, sat up soon after and the pair were sucked back into the main bunch, leaving the lesser-known escapees to flee up the road.
They built up a substantial lead through the day and when it touched 10 minutes it became clear the stage victory would come down to a straight fight between the group.
Joly was the first to attack in the closing stages, but as as soon as he was reeled in, Mercado took flight.
He was joined by Garcia-Acosta, and the pair worked well together to open a gap that reached 30 seconds before the chasing quartet began to make headway into that lead.
But they held an advantage to the finishing line where Mercado jumped off his rivals wheel to take a memorable first victory in the race, with Fofonov leading the rest of the breakway home 11 seconds down.
After the trials and tribulations of the mountain stages the sprinters took centre stage when the peloton rolled into Lons-le-Saunier.
Norway's Thor Hushovd took the honours from Robbie McEwen in a blanket finish that also included Danilo Hondo and Stuart O'Grady.
Armstrong remains 4:09 clear of Ivan Basso in the general classification, but will be confident of extending that lead in Saturday's time-trial.