Team Sky's Froome attacked on the steep climb to Peña Cabarga at the end of the 211km stage 17 into the region Cantabria in northern Spain to finish one second clear of Cobo - and take 20 vital bonus seconds.
Froome now trails Geox's Cobo by just 13 seconds in the GC with four stages left to ride before the race's conclusion in Madrid on Sunday.
Bradley Wiggins, Froome's compatriot and team-mate, finished 39 seconds down but conserves his third place in the GC, despite a spirited ride by young Dutchman Bauke Mollema (Rabobank), who took third on the day.
But all eyes were on the scintillating duel between the Kenyan-born Froome and race leader Cobo.
Both riders stuck to each other like glue for the opening moments of the climb as the likes of Dan Martin, the Irish stage nine winner from Garmin-Cevelo, and Belgium's Jurgen van den Broeck (Omega Pharma-Lotto) both put in bids to break clear.
It was van den Broeck who looked strongest when he dropped the hammer inside the final 2km, dropping the other favourites and causing last year's winner at Peña Cabarga - the Spaniard Joaquim Rodriguez (Katusha) - to crack.
Spaniard Mikel Nieve (Euskaltel) led the chase to reel in van den Broeck - before the Froome-Cobo show took over.
The Spaniard made an initial attack just before the 1km-to-go banner and only Froome was able to follow his wheel on the steep 18-percent section of the deciding climb.
Froome then made his move, jumping out of the saddle to put in a massive dig to which Cobo had no answer.
With stage 15 winner Cobo distanced, it looked like Froome was riding back into the red jersey he wore for one day following the ITT in Salamanca in what would have been without a doubt Team Sky's crowning moment as a professional cycling team.
But 30-year-old Cobo - perhaps inspired by the throngs of fervent Spanish fans chanting his name on the precipitous slopes of the mountain - refound his rhythm and somehow managed to ride back onto the wheel of his rival with just 200m left to the finish.
Froome's dream finale then looked like to turn into a nightmare when Cobo pulled ahead inside the closing 100m - only for the 26-year-old Froome to give it his all on the final left-hand bend, and roar to his first ever Grand Tour stage win.
Cobo crossed the line one second down - but his 12-second bonus for finishing runner-up means he only conceded nine seconds in the GC to his closest rival.
Mollema took third place, 21 seconds down, while Cobo's Geox team-mate Denis Menchov was fourth, a few seconds ahead of Euskaltel pair Igor Anton and Nieve.
With Wiggins now 1:41 down in the GC, and fourth-place Mollema a further 24 seconds back, the 66th edition of the Vuelta looks to be a two-way battle between Cobo and Froome - although the absence of any more summit finishes or a time trial makes the Spaniard the clear favourite.
But the time bonus system used by the Vuelta means this final destiny of the red jersey could well be undecided right up to the 11th hour.
The race continues on Thursday with the rugged 175km stage 18 from Solares to the coastal town of Noja that features four climbs - including the Cat.1 Puerto de Alisas - but which finishes on the flat.